Android Question Compiling error: Failed resolution of: Landroid/support/v4/app/NotificationCompat$Builder

pompierecattivo

Member
Licensed User
Longtime User
Hello there,
first of all sorry for my english and for my bad knowledge of code and libraries..
The problem where i'm falling is relatet to an app correctly comiled since some mounths ago. Dont remember the B4A latest version because i've resumed my system from a backup, but actually i've 9.50 installed. So i try to compile again my app but when installed on device the app crash and log report data i paste here. I try to search other similar problems on forum but sincerely not able to olve. As answer to others users with same problem, always "you" ask to paste the part of code where problem start, but unfortunately in my case the app dont start completely. I've tryed some purposed solution by update/install libraries from B4A SDK manager, but unlucky on it..
Really dont know how to do and where to start.
Any help appreciate.

B4X:
Copying updated assets files (40)
*** Service (starter) Create ***
java.lang.NoClassDefFoundError: Failed resolution of: Landroid/support/v4/app/NotificationCompat$Builder;
    at barxdroid.NotificationBuilder.NotificationBuilder.Initialize(NotificationBuilder.java:55)
    at com.rbsoft.sardroid.starter$ResumableSub_Service_Create.resume(starter.java:2007)
    at com.rbsoft.sardroid.starter._service_create(starter.java:1944)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:732)
    at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:348)
    at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:255)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:144)
    at anywheresoftware.b4a.BA.raiseEvent(BA.java:176)
    at com.rbsoft.sardroid.starter.onCreate(starter.java:56)
    at android.app.ActivityThread.handleCreateService(ActivityThread.java:3193)
    at android.app.ActivityThread.-wrap5(ActivityThread.java)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1569)
    at android.os.Handler.dispatchMessage(Handler.java:102)
    at android.os.Looper.loop(Looper.java:154)
    at android.app.ActivityThread.main(ActivityThread.java:6130)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:889)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:779)
Caused by: java.lang.ClassNotFoundException: Didn't find class "android.support.v4.app.NotificationCompat$Builder" on path: DexPathList[[zip file "/data/app/com.rbsoft.sardroid-1/base.apk"],nativeLibraryDirectories=[/data/app/com.rbsoft.sardroid-1/lib/arm64, /system/lib64, /vendor/lib64]]
    at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:380)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
    ... 20 more
java.lang.RuntimeException: Unable to create service com.rbsoft.sardroid.starter: java.lang.RuntimeException: java.lang.NoClassDefFoundError: Failed resolution of: Landroid/support/v4/app/NotificationCompat$Builder;
    at android.app.ActivityThread.handleCreateService(ActivityThread.java:3203)
    at android.app.ActivityThread.-wrap5(ActivityThread.java)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1569)
    at android.os.Handler.dispatchMessage(Handler.java:102)
    at android.os.Looper.loop(Looper.java:154)
    at android.app.ActivityThread.main(ActivityThread.java:6130)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:889)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:779)
Caused by: java.lang.RuntimeException: java.lang.NoClassDefFoundError: Failed resolution of: Landroid/support/v4/app/NotificationCompat$Builder;
    at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:175)
    at anywheresoftware.b4a.BA.raiseEvent(BA.java:176)
    at com.rbsoft.sardroid.starter.onCreate(starter.java:56)
    at android.app.ActivityThread.handleCreateService(ActivityThread.java:3193)
    ... 8 more
Caused by: java.lang.NoClassDefFoundError: Failed resolution of: Landroid/support/v4/app/NotificationCompat$Builder;
    at barxdroid.NotificationBuilder.NotificationBuilder.Initialize(NotificationBuilder.java:55)
    at com.rbsoft.sardroid.starter$ResumableSub_Service_Create.resume(starter.java:2007)
    at com.rbsoft.sardroid.starter._service_create(starter.java:1944)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:732)
    at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:348)
    at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:255)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:144)
    ... 11 more
Caused by: java.lang.ClassNotFoundException: Didn't find class "android.support.v4.app.NotificationCompat$Builder" on path: DexPathList[[zip file "/data/app/com.rbsoft.sardroid-1/base.apk"],nativeLibraryDirectories=[/data/app/com.rbsoft.sardroid-1/lib/arm64, /system/lib64, /vendor/lib64]]
    at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:380)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
    ... 20 more
 

DonManfred

Expert
Licensed User
Longtime User
did you jetified all libraries? IDE->Tools->Jetifier (AndroidX)
 
Upvote 0

pompierecattivo

Member
Licensed User
Longtime User
.....didnt before.... Just do it and all work perfectly. Many thanks. Can i ask you in 4-5 easy words what happen with "jetifications"?
Thanks anyway, of course!
 
Upvote 0
Top