When has the internet library loaded?
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
When has the internet library loaded?
Hi,
Is there a message that I can monitor that indicates that the Internet Library has loaded? Or all libraries have loaded?
The docs just say don't used a command at startup, preOpenStack... Not very precise.
THX,
Simon
Is there a message that I can monitor that indicates that the Internet Library has loaded? Or all libraries have loaded?
The docs just say don't used a command at startup, preOpenStack... Not very precise.
THX,
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
-
- VIP Livecode Opensource Backer
- Posts: 10058
- Joined: Sat Apr 08, 2006 7:05 am
- Contact:
Re: When has the internet library loaded?
What conflict are you having with it?
There are ways to invoke it whenever you need it.
There are ways to invoke it whenever you need it.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
Re: When has the internet library loaded?
Simon, the internet library is included in a hidden group on your mainStack and is not available until after it loads (following the load order through the message path).. You can always include a backScript to listen for the libraryStack message and the you can check against the list of stacksInUse to see if the internet library is loaded
Re: When has the internet library loaded?
Thanks Richard & Shaosean for your reply's.
After upgrading to LC 5.x my applications started throwing an error on libUrlSetSSLVerification false that I put down to the internet library not being loaded. Since my apps mainly communicate with servers I want to start using the library as soon as possible, just to test if the user is online.
I will investigate Shaosean's suggestions and see what happens.
Simon
After upgrading to LC 5.x my applications started throwing an error on libUrlSetSSLVerification false that I put down to the internet library not being loaded. Since my apps mainly communicate with servers I want to start using the library as soon as possible, just to test if the user is online.
I will investigate Shaosean's suggestions and see what happens.
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
Re: When has the internet library loaded?
Libraries are included in a standalone as an hidden group, and so they will load after the first card's background loads. Basically you can count on them being available after the first card is open (it's actually a bit sooner than that, but waiting for the card to open will always work.)
I don't think the librarystack message is sent for groups, is it?
I don't think the librarystack message is sent for groups, is it?
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
Re: When has the internet library loaded?
hmmm...
I just made a new stack with:
and it threw an error again.
but:
Does work.
It must be the libUrl, is there something different about it?
Simon
EDIT: error message
executing at 11:12:23 AM
Type Handler: can't find handler
Object card id 1002
Line libUrlSetSSLVerification false
Hint libUrlSetSSLVerification
I just made a new stack with:
Code: Select all
on openCard
libUrlSetSSLVerification false
end openCard
but:
Code: Select all
on openCard
load url "http://www.runrev.com/"
end openCard
It must be the libUrl, is there something different about it?
Simon
EDIT: error message
executing at 11:12:23 AM
Type Handler: can't find handler
Object card id 1002
Line libUrlSetSSLVerification false
Hint libUrlSetSSLVerification
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
Re: When has the internet library loaded?
OK another data point.
This is acting like the breakpoint troubles. Opening the stack from the IDE File>Open does not throw the error, double clicking on the .livecode file does. Both occur since the release of LC 5.x. Not a big problem if that's all it really is.
Simon
This is acting like the breakpoint troubles. Opening the stack from the IDE File>Open does not throw the error, double clicking on the .livecode file does. Both occur since the release of LC 5.x. Not a big problem if that's all it really is.
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
Re: When has the internet library loaded?
Sounds like the IDE hasn't loaded libURL yet. If you open the stack from the File menu then everything has already loaded. Your own apps will likely act the same way.
For your apps you could do a "send" on openCard that calls a handler which in turn sets the libURL functions. Send the message in 1 second or so, to give everything else time to load.
For your apps you could do a "send" on openCard that calls a handler which in turn sets the libURL functions. Send the message in 1 second or so, to give everything else time to load.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com