Android Question The filename or extension is too long

Calvin Yee

Member
Licensed User
Now I have the error "The filename or extension is too long" when i compile the project.

I am using version b4A 10.0
please advice.

B4X:
B4A Version: 10.0
Java Version: 8
Parsing code.    (0.71s)
Building folders structure.    (0.15s)
Compiling code.    (0.57s)
Compiling layouts code.    (0.16s)
Organizing libraries.    (0.00s)
    (AndroidX SDK)
Generating R file.    (0.00s)
Compiling generated Java code.    Error
The filename or extension is too long
 

DonManfred

Expert
Licensed User
Longtime User
My guess is that you need to switch to java 11
 
Last edited:
Upvote 0

agraham

Expert
Licensed User
Longtime User
I thought that Erel was fixing this in version 10.0 - perhaps not!
My guess is that you need to switch to java 11
I don't think that would help.
 
Upvote 0

Calvin Yee

Member
Licensed User
Do you any guildeline/tutorial, because I have no Idea how to split it into several "subprojects" and compile them as libraries.
 
Upvote 0

omo

Active Member
Licensed User
Longtime User
Hope is not because you have your project folder inside other subfolders that makes its filename extension longer? Try to copy your main project folder directly into C: drive, run and recompile your project from there to shorten filename extension
 
Upvote 0

Erel

B4X founder
Staff member
Licensed User
Longtime User
Do you any guildeline/tutorial, because I have no Idea how to split it into several "subprojects" and compile them as libraries.
You need to find a set of classes that don't depend on any other module, and move them to a new project. You can then compile them with Project - Compile As Library. It will create a jar and xml file that you need to put in the libraries folder and reference from the main project.
 
Upvote 0
Top