I iCAB Well-Known Member Licensed User Longtime User Nov 14, 2020 #1 Hi All, I am getting this error now. It happens whenever I click a SlideSwitch. java.lang.NoClassDefFoundError: Failed resolution of: Landroid/support/v4/view/MotionEventCompat; I believe it is related to upgrading to B4A 10.2 and/or the android_sdk Last actions: re-installed B4A 10.2 fresh install of android SDK manager deleted appcompat from internal libraries folders downloaded appcompat 4.0 and unzipped in internal folder. I am also attaching the full error log. Can someone help please. Thanks, ICAB Attachments ErrorLog.txt ErrorLog.txt 4.1 KB · Views: 1,904
Hi All, I am getting this error now. It happens whenever I click a SlideSwitch. java.lang.NoClassDefFoundError: Failed resolution of: Landroid/support/v4/view/MotionEventCompat; I believe it is related to upgrading to B4A 10.2 and/or the android_sdk Last actions: re-installed B4A 10.2 fresh install of android SDK manager deleted appcompat from internal libraries folders downloaded appcompat 4.0 and unzipped in internal folder. I am also attaching the full error log. Can someone help please. Thanks, ICAB
DonManfred Expert Licensed User Longtime User Nov 14, 2020 #2 iCAB said: deleted appcompat from internal libraries folders Click to expand... WHY? NO single reason to delete any of the internal libbraries. Where does the dependency of android/support/v4/view/MotionEventCompat come from? Try to change the dependency to the matching AndroidX Artifact. Upvote 0
iCAB said: deleted appcompat from internal libraries folders Click to expand... WHY? NO single reason to delete any of the internal libbraries. Where does the dependency of android/support/v4/view/MotionEventCompat come from? Try to change the dependency to the matching AndroidX Artifact.
I iCAB Well-Known Member Licensed User Longtime User Nov 14, 2020 #3 Thanks Don for your reply DonManfred said: WHY? NO single reason to delete any of the internal libbraries. Click to expand... I was reading this thread: https://www.b4x.com/android/forum/t...-view-viewconfigurationcompat.117655/#content, in post #13 Erel suggested to delete the internal appcompat and install the latest one, so I tried it just in case. It didn't make a difference. I can restore the old one if needed. DonManfred said: Where does the dependency of android/support/v4/view/MotionEventCompat come from? Try to change the dependency to the matching AndroidX Artifact. Click to expand... I have no idea, to be honest with you. All what I know is that this code was working for years as is. I am not sure at which point this started happening. Also I am not sure if it makes any difference, but it is worth mentioning that the SlideSwitch was added using code and the the designer. Other posts suggested to run Jetify, which I did as well, Any ideas? Thanks, iCAB Upvote 0
Thanks Don for your reply DonManfred said: WHY? NO single reason to delete any of the internal libbraries. Click to expand... I was reading this thread: https://www.b4x.com/android/forum/t...-view-viewconfigurationcompat.117655/#content, in post #13 Erel suggested to delete the internal appcompat and install the latest one, so I tried it just in case. It didn't make a difference. I can restore the old one if needed. DonManfred said: Where does the dependency of android/support/v4/view/MotionEventCompat come from? Try to change the dependency to the matching AndroidX Artifact. Click to expand... I have no idea, to be honest with you. All what I know is that this code was working for years as is. I am not sure at which point this started happening. Also I am not sure if it makes any difference, but it is worth mentioning that the SlideSwitch was added using code and the the designer. Other posts suggested to run Jetify, which I did as well, Any ideas? Thanks, iCAB
I iCAB Well-Known Member Licensed User Longtime User Nov 14, 2020 #4 I can also repeat the problem using the SlideSwitch sample project provided in this link: https://www.b4x.com/android/forum/threads/slideswitch-v1-0-2.51749/ Hope this will help Thanks, iCAB Upvote 0
I can also repeat the problem using the SlideSwitch sample project provided in this link: https://www.b4x.com/android/forum/threads/slideswitch-v1-0-2.51749/ Hope this will help Thanks, iCAB
Erel B4X founder Staff member Licensed User Longtime User Nov 15, 2020 #5 Carefully follow the installation instructions and everything will work: https://www.b4x.com/b4a.html Upvote 0
Carefully follow the installation instructions and everything will work: https://www.b4x.com/b4a.html
I iCAB Well-Known Member Licensed User Longtime User Nov 15, 2020 #6 I have followed the instructions several times and installed B4A from scratch on multiple stations. Some of the libraries that we are using require updating some of the packages in the SDK Manager, and therefore after completing the instructions I find that I still have to run the SDK manager GUI and install the recommended updates. Is there anything that I can try without having to uninstall and re-install everything? Upvote 0
I have followed the instructions several times and installed B4A from scratch on multiple stations. Some of the libraries that we are using require updating some of the packages in the SDK Manager, and therefore after completing the instructions I find that I still have to run the SDK manager GUI and install the recommended updates. Is there anything that I can try without having to uninstall and re-install everything?
Erel B4X founder Staff member Licensed User Longtime User Nov 16, 2020 #7 You need to run the jetifier tool. SlideSwitch is based on the old Android Support library. Why aren't you using the nicer, cross platform B4XSwitch view? Upvote 0
You need to run the jetifier tool. SlideSwitch is based on the old Android Support library. Why aren't you using the nicer, cross platform B4XSwitch view?
I iCAB Well-Known Member Licensed User Longtime User Nov 16, 2020 #8 Hi Erel Erel said: You need to run the jetifier tool. SlideSwitch is based on the old Android Support library. Click to expand... Sorry I forgot to mention that I already did that Erel said: Why aren't you using the nicer, cross platform B4XSwitch view? Click to expand... Up until this incident, the code is working good for me, as I can control the slideswitch a bit more, in terms of size & color. I would like to have this issue resolved somehow as I hate to change the current layout, and the exact same code is used in several apps. Please let me know what else I can try. Thanks, iCAB Upvote 0
Hi Erel Erel said: You need to run the jetifier tool. SlideSwitch is based on the old Android Support library. Click to expand... Sorry I forgot to mention that I already did that Erel said: Why aren't you using the nicer, cross platform B4XSwitch view? Click to expand... Up until this incident, the code is working good for me, as I can control the slideswitch a bit more, in terms of size & color. I would like to have this issue resolved somehow as I hate to change the current layout, and the exact same code is used in several apps. Please let me know what else I can try. Thanks, iCAB
Erel B4X founder Staff member Licensed User Longtime User Nov 16, 2020 #9 Have you put the library in the additional libraries folder? If it is in the internal folder it will not be jetified. Upvote 0
Have you put the library in the additional libraries folder? If it is in the internal folder it will not be jetified.
I iCAB Well-Known Member Licensed User Longtime User Nov 16, 2020 #10 It's working after moving the SlideSwitch library to the additional libraries folder and running jetifier. Thanks for the exceptional support. You're the best. iCAB Upvote 0
It's working after moving the SlideSwitch library to the additional libraries folder and running jetifier. Thanks for the exceptional support. You're the best. iCAB