Java Question SLC import does not exist

abilio486software

Active Member
Licensed User
When compiling a library, I'm getting this error:

Starting step: Compiling Java code.
javac 1.8.0_241
C:\Users\Abílio\Desktop\SimpleLibraryCompiler\SIBS\src\b4x\example\libSIBS.java:36: error: package android.support.v4.app does not exist
import android.support.v4.app.TaskStackBuilder;
^
Note: C:\Users\Abílio\Desktop\SimpleLibraryCompiler\SIBS\src\b4x\example\libSIBS.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
1 error


Error.

Any possible solution?
 

agraham

Expert
Licensed User
Longtime User

abilio486software

Active Member
Licensed User
android.support.* types are from the old and no longer used Android Support library
A library that depends on android.support is an old, unmaintained library that shouldn't be used.
Hi Erel,

You have a right to your opinion, but the problem of my clients is not solved, just because I want to ignore it.

Like it or not, I have to put the Nexgo N3 terminal to work with my app, which is made in B4A.

In fact I would like to be able to implement onActivityResult through "inline java" but I get the information that is already declared in Main.

So I tried to make a library, but unfortunately SLC does not compile successfully (but B4A compiles successfully), so I asked you for help, because you were the one who coded the SLC.

How can I solve the problem?
 

drgottjr

Expert
Licensed User
Longtime User
how can you not know what to do for a missing dependency? go to maven and download it. or send me a pm and i'll send one to you.
 

abilio486software

Active Member
Licensed User
how can you not know what to do for a missing dependency? go to maven and download it. or send me a pm and i'll send one to you.

Many thanks,

Library project does not compile, but B4A project with inline java compiles without errors with the configuration in the picture.


1615990101603.png
 

Attachments

  • SIBS.zip
    208.1 KB · Views: 344

drgottjr

Expert
Licensed User
Longtime User
limiting my comments to what i see in your first post, you are missing the android.support.v4 package when you compile with slc. whether that means you actually have it somewhere on your system or not, i can't say. you can either find it at the maven or jar-download repositories and download it yourself, or you can do what i said previously and i'll send you an old android.support.v4 jar that i have. what you do with it or whether it solves the problem, i can't say. resolving 1 missing dependency can often lead to other missing entities. and something doesn't look quite right with that list of #additionaljar references you have in your b4a version. but one step at a time.
the attached image shows you what you get if you go to google and type "maven android.support.v4" or similar. follow the links or pm me.
 

Attachments

  • 1.png
    1.png
    49.7 KB · Views: 314

drgottjr

Expert
Licensed User
Longtime User
whether it exists or not, i can't say. whether it solves your problem, i don't know. but i have it. do you want it?
 

Attachments

  • 1.png
    1.png
    40.1 KB · Views: 350
Top