Using return in a command script
Peter M. Brigham
pmbrig at gmail.com
Fri Oct 28 14:33:19 EDT 2016
Keep in mind that you can use the dialogData to return values from command handlers, or function handlers for that matter:
…
set the dialogData to “false”
end myHandler
— Peter
Peter M. Brigham
pmbrig at gmail.com
> On Oct 27, 2016, at 10:31 AM, Bob Sneidar <bobsneidar at iotecdigital.com> wrote:
>
> Thanks Monte. I've come to see that returning a value from a built in message handler is a no go.
>
> Bob S
>
>
> On Oct 26, 2016, at 16:36 , Monte Goulding <monte at appisle.net<mailto:monte at appisle.net>> wrote:
>
> OK, just to make sure I understand you I’ll summarise in code:
>
> on openCard
> go card “database setup”
> if the result is false then
> — database setup failed
> end if
> end openCard
>
> — database setup card script
> on openCard
> — do stuff
> return stuffFailed
> end openCard
>
> If ^ is what you are doing then no it won’t work. The result after the go command is an error message if it failed rather than anything returned by openCard.
>
> Cheers
>
> Monte
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
More information about the use-livecode
mailing list