aedwall Active Member Licensed User Longtime User Feb 20, 2018 #1 My project works with v7.30, but does not work with v7.80: Compiling generated Java code. Error B4A line: 55 Log(Response.GetString(\ javac 1.8.0_66 src\anywheresoftware\b4a\helen\httputils2service.java:158: error: cannot access ParseException anywheresoftware.b4a.keywords.Common.Log(_response.GetString("UTF8")); ^ class file for org.apache.http.ParseException not found
My project works with v7.30, but does not work with v7.80: Compiling generated Java code. Error B4A line: 55 Log(Response.GetString(\ javac 1.8.0_66 src\anywheresoftware\b4a\helen\httputils2service.java:158: error: cannot access ParseException anywheresoftware.b4a.keywords.Common.Log(_response.GetString("UTF8")); ^ class file for org.apache.http.ParseException not found
DonManfred Expert Licensed User Longtime User Feb 20, 2018 #2 aedwall said: class file for org.apache.http.ParseException not found Click to expand... It has nothing to do with the b4a 7.3 or 7.8. The Device you are using is running Android 5+ i guess. You need to switch to okhttp! Switch from httputils2 to okhttp and okhttputils2 https://www.b4x.com/android/forum/threads/okhttp-replaces-the-http-library.54723/#content Upvote 0
aedwall said: class file for org.apache.http.ParseException not found Click to expand... It has nothing to do with the b4a 7.3 or 7.8. The Device you are using is running Android 5+ i guess. You need to switch to okhttp! Switch from httputils2 to okhttp and okhttputils2 https://www.b4x.com/android/forum/threads/okhttp-replaces-the-http-library.54723/#content
Erel B4X founder Staff member Licensed User Longtime User Feb 20, 2018 #3 DonManfred said: It has nothing to do with the b4a 7.3 or 7.8. Click to expand... That's true. It is related to the android.jar version. Upvote 0
DonManfred said: It has nothing to do with the b4a 7.3 or 7.8. Click to expand... That's true. It is related to the android.jar version.
aedwall Active Member Licensed User Longtime User Feb 20, 2018 #4 DonManfred said: It has nothing to do with the b4a 7.3 or 7.8. The Device you are using is running Android 5+ i guess. You need to switch to okhttp! Switch from httputils2 to okhttp and okhttputils2 https://www.b4x.com/android/forum/threads/okhttp-replaces-the-http-library.54723/#content Click to expand... Thank you. I have to say I am confused by all these different platform numbers, 17, 19, 23, 27, etc. I have no idea what to specify or what is required. I think that I should specify platform 17 if I want folks with Jellybean to be able to use my code. If I specify 27, then only those folks with Oreo or whatever the last version of Android was can use it. Am I right in this assumption? Upvote 0
DonManfred said: It has nothing to do with the b4a 7.3 or 7.8. The Device you are using is running Android 5+ i guess. You need to switch to okhttp! Switch from httputils2 to okhttp and okhttputils2 https://www.b4x.com/android/forum/threads/okhttp-replaces-the-http-library.54723/#content Click to expand... Thank you. I have to say I am confused by all these different platform numbers, 17, 19, 23, 27, etc. I have no idea what to specify or what is required. I think that I should specify platform 17 if I want folks with Jellybean to be able to use my code. If I specify 27, then only those folks with Oreo or whatever the last version of Android was can use it. Am I right in this assumption?
lemonisdead Well-Known Member Licensed User Longtime User Feb 20, 2018 #5 Android platform versions : https://developer.android.com/about/dashboards/index.html Some further readings about targetSdkVersion : https://www.b4x.com/android/forum/threads/android-jar-targetsdkversion-minsdkversion.87610/ Upvote 0
Android platform versions : https://developer.android.com/about/dashboards/index.html Some further readings about targetSdkVersion : https://www.b4x.com/android/forum/threads/android-jar-targetsdkversion-minsdkversion.87610/
aedwall Active Member Licensed User Longtime User Feb 20, 2018 #6 DonManfred said: It has nothing to do with the b4a 7.3 or 7.8. The Device you are using is running Android 5+ i guess. You need to switch to okhttp! Switch from httputils2 to okhttp and okhttputils2 https://www.b4x.com/android/forum/threads/okhttp-replaces-the-http-library.54723/#content Click to expand... I have tried to do this and I get the attached error message: I don't know where to look in order to find the second declaration. UPDATE: I downloaded the file named "HttpUtils2_Src.zip" and put those 2 .bas files into my project, replacing what I had. I might have done something else - I don't remember. But it is now working. Oh, I think I removed the "OkHttpUtils2" library from the project. I'm not sure what I am doing, but it now runs on the emulator. Attachments Screenshot_2.png 2 KB · Views: 621 Screenshot_3.png 7.1 KB · Views: 624 Screenshot_4.png 3.4 KB · Views: 650 Screenshot_5 - new library setup.png 6.4 KB · Views: 557 Last edited: Feb 20, 2018 Upvote 0
DonManfred said: It has nothing to do with the b4a 7.3 or 7.8. The Device you are using is running Android 5+ i guess. You need to switch to okhttp! Switch from httputils2 to okhttp and okhttputils2 https://www.b4x.com/android/forum/threads/okhttp-replaces-the-http-library.54723/#content Click to expand... I have tried to do this and I get the attached error message: I don't know where to look in order to find the second declaration. UPDATE: I downloaded the file named "HttpUtils2_Src.zip" and put those 2 .bas files into my project, replacing what I had. I might have done something else - I don't remember. But it is now working. Oh, I think I removed the "OkHttpUtils2" library from the project. I'm not sure what I am doing, but it now runs on the emulator.
Erel B4X founder Staff member Licensed User Longtime User Feb 21, 2018 #7 Why do you need the source code? Unless you need to modify it just add a reference to OkHttpUtils2 and remove HttpJob and HttpUtils2Service modules. Also remove the reference to Http and HttpUtils2 libraries. Upvote 0
Why do you need the source code? Unless you need to modify it just add a reference to OkHttpUtils2 and remove HttpJob and HttpUtils2Service modules. Also remove the reference to Http and HttpUtils2 libraries.
aedwall Active Member Licensed User Longtime User Feb 21, 2018 #8 Because I could not get it to work any other way. It works now, so that's kind of all I care about. I don't remember how I did everything back when I originally made this project - it was long ago. But it worked back then with an old version of b4A and it works now with v7.80 (if I use the old version of my Swiss Ephemeris library). UPDATE: I did what you suggested and everything appears to still be working. Thank you. Upvote 0
Because I could not get it to work any other way. It works now, so that's kind of all I care about. I don't remember how I did everything back when I originally made this project - it was long ago. But it worked back then with an old version of b4A and it works now with v7.80 (if I use the old version of my Swiss Ephemeris library). UPDATE: I did what you suggested and everything appears to still be working. Thank you.
KMatle Expert Licensed User Longtime User Feb 21, 2018 #9 Another hint: Me and a lot of users here use OkHttputils in many projects exchanging millions data via servers with databases. I never had any issues with B4x. Be sure that B4x is absolutely stable. IF there is a problem it is 100% due to programming mistakes/not updatung, etc. Upvote 0
Another hint: Me and a lot of users here use OkHttputils in many projects exchanging millions data via servers with databases. I never had any issues with B4x. Be sure that B4x is absolutely stable. IF there is a problem it is 100% due to programming mistakes/not updatung, etc.