Android POST Command Fails
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Android POST Command Fails
I think the internet library is not being generated. No DLL's in the directory where the apk is created when saving for Android. I have looked for anything labeled internet in the LiveCode folders, hoping to find the library and manually include it with my build. No luck. I have tried on three versions, with the last version being LC 6.1.2 (rc 1).
-
- VIP Livecode Opensource Backer
- Posts: 3901
- Joined: Sat Mar 24, 2007 2:54 am
- Location: Palo Alto
Re: Android POST Command Fails
Hi ddupont,
All needed libraries will be inside the apk not a separate file (that is if they are even called libraries at that point).
Make sure you have "Internet" selected in the standalone builder and any other controls you need.
No manual copying of files is needed. When you have the app setup correctly everything will be inside the single apk. Even all your "Copy Files".
Simon
All needed libraries will be inside the apk not a separate file (that is if they are even called libraries at that point).
Make sure you have "Internet" selected in the standalone builder and any other controls you need.
No manual copying of files is needed. When you have the app setup correctly everything will be inside the single apk. Even all your "Copy Files".
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
Re: Android POST Command Fails
I have used the "Search for " automatic function and have done the manual method of clicking on Internet, etc. The post command does nothing. The app has the results of the post command going to a field. Nothing shows up in the field. Works great running the app in LiveCode on my Windows machine and as a Windows Stand-alone app (where the revsecurity.dll is created in the same folder as the stand-alone Windows app). But making it for Android results in nothing happening in the app.
-
- VIP Livecode Opensource Backer
- Posts: 3901
- Joined: Sat Mar 24, 2007 2:54 am
- Location: Palo Alto
Re: Android POST Command Fails
"Internet" is in the Android standalone settings not in "General" tab.
Do you have that selected?
Simon
Do you have that selected?
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
Re: Android POST Command Fails
Hi ddupont,
The DLLs that you mention are specific to the Windows platform so will not be included in the Android APK.
The POST command is available to use on the Android platform even though the libURL internet library is not supported on the mobile platform.
As Simon has mentioned, you must ensure that "Internet" is enabled in the Android standalone settings. Please see the attached picture that shows this setting.
If this is the cause of the issue, enabling "Internet" should allow the POST command to function as expected.
Kind Regards,
Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
--
The DLLs that you mention are specific to the Windows platform so will not be included in the Android APK.
The POST command is available to use on the Android platform even though the libURL internet library is not supported on the mobile platform.
As Simon has mentioned, you must ensure that "Internet" is enabled in the Android standalone settings. Please see the attached picture that shows this setting.
If this is the cause of the issue, enabling "Internet" should allow the POST command to function as expected.
Kind Regards,
Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
--
Re: Android POST Command Fails
And to complete the last answer : be careful with the POST bug.
See :
http://forums.runrev.com/viewtopic.php?f=66&t=16195
You'll have to rePOST, if you receive the "java.io.EOFException" error message.
See :
http://forums.runrev.com/viewtopic.php?f=66&t=16195
You'll have to rePOST, if you receive the "java.io.EOFException" error message.
Re: Android POST Command Fails
Yes, Internet is selected on the Android tab as well as on the general tab.
Re: Android POST Command Fails
Hi ddupont,
Could you upload a sample stack that shows that shows how you are executing the POST command? This will allow us to investigate the issue and try to track down what coud be causing it.
Kind Regards,
Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
--
Could you upload a sample stack that shows that shows how you are executing the POST command? This will allow us to investigate the issue and try to track down what coud be causing it.
Kind Regards,
Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
--
Re: Android POST Command Fails
I am using another person's stack, which I have attached.
- Attachments
-
- AndroidGCM-for-Android.zip
- (4.67 KiB) Downloaded 250 times
Re: Android POST Command Fails
Hi ddupont,
thank you for supplying the sample stack
On the card script of the supplied stack, libUrlSetSSLVerification is being set to false. As this command is not yet compatible on mobile it will cause a silent break in your Application with no script following it being executed.
You can see a more visual representation of this by commenting out the libUrlSetSSLVerification line and then simply answering tNotification.
e.g.
With the libUrlSetSSLVerification command commented out, the POST command should function.
With that being said, if the libURLSetSSLVerification command is required for this stack to operate, then there is the possiblity it will not run on the mobile platforms. I would recommend discussing this with the author of the stack if this is the case.
Kind Regards,
Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
--
thank you for supplying the sample stack
On the card script of the supplied stack, libUrlSetSSLVerification is being set to false. As this command is not yet compatible on mobile it will cause a silent break in your Application with no script following it being executed.
You can see a more visual representation of this by commenting out the libUrlSetSSLVerification line and then simply answering tNotification.
e.g.
Code: Select all
# had a couple of errors that were resolved by setting/resetting this flag :/
--libUrlSetSSLVerification false
# send the notification
answer tNotification
--post tNotification to url "https://android.googleapis.com/gcm/send"
--return it
With that being said, if the libURLSetSSLVerification command is required for this stack to operate, then there is the possiblity it will not run on the mobile platforms. I would recommend discussing this with the author of the stack if this is the case.
Kind Regards,
Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
--
-
- VIP Livecode Opensource Backer
- Posts: 3901
- Joined: Sat Mar 24, 2007 2:54 am
- Location: Palo Alto
Re: Android POST Command Fails
Hi ddupont,
This stack wasn't made to run on Android, but to send push notifications to Android.
That "libUrlSetSSLVerification" does not work with Android.
Can it be made to run on Android? Probably.
Simon
This stack wasn't made to run on Android, but to send push notifications to Android.
That "libUrlSetSSLVerification" does not work with Android.
Can it be made to run on Android? Probably.
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
Re: Android POST Command Fails
Removing the libUrlSetSSLVerification setting did the trick. There is still hope for me as I have learned something.
Thank you for your assistance. LiveCode is very friendly but it still takes time to understand it all. Especially for me since I am a beginner.
Thank you!
Thank you for your assistance. LiveCode is very friendly but it still takes time to understand it all. Especially for me since I am a beginner.
Thank you!