Android Question Puzzling Compile error

Cableguy

Expert
Licensed User
Longtime User
Hi Guys...

A simple code consisting of a layout file, a 1 line main sub and a 2 subs class module is giving me this error withou any details in compile.

B4X:
Parsing code.                          0.02
Compiling code.                        0.19
Compiling layouts code.                0.02
Generating R file.                      0.30
Compiling generated Java code.          Error
javac 1.7.0_25
gen\b4a\example\R.java:14: error: <identifier> expected
        public static final int 1=0x7f020000;
                              ^
1 error

I am sure my code is good and will post if necessary, but I'm guessing that this has nothing to do with my codem but with some "file save" fail.

EDIT.
Just copied/pasted my subs to another instance of B4A IDE (not a blanc project from the same instance of B4A) and it compiled flawlessly...
This is an issue that comes from a few versions back if I recall correctly...
RE-EDIT.
Spoke too soon...
There seems to be some interaction between the compliler and the "Bridge" tool...
First compile attempt without bridge went fine, then whe I connected my device through wireless, the same error came up... Turning off brigde does not eleminate the error.
 
Last edited:

Cableguy

Expert
Licensed User
Longtime User
I found my problem...
One of my subs was the famous "SetNinePatchDrawable" Sub... AND as image name I used numbers... wich proves to be a "NO-NO"...
Erel, perhaps a small edit to the 9Patch tutorial would be usefull for everyone...
Always name the image in lowercase and never start the image name with numbers
Got it working!
 
Upvote 0
Top