LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!
What would be the best way to "refresh" a card? I have a card where I am updating dropdown fields from a SQL database. When a update is done, I want to rerun the "on opencard" function which contains the statements to load my dropdown fields. Should I just close and reopen the card or can I specify a call to the "on opencard" function?
You can make a new handler, which contains the entire openCard handler, but with a different name. Call this handler from the openCard handler and from the handler that is supposed to refresh the card. There is no need to go to a different card and back.
Best,
Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
on handlerName
-- do something here
end handlerName
You can call it, simply by issueing the command. You don't need to use the call command.
Best,
Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode