What is wrong with this script?
charles61
cszasz at mac.com
Thu Nov 4 22:42:28 EDT 2010
Jacqueline,
I am using the handler to send mouseUp commands to Print Only cards for printing. I will try your suggestion of combing two commands in a handler. And, yes I did try command period several times without success.
Charles Szasz
cszasz at mac.com
On Nov 4, 2010, at 9:23 PM, J. Landman Gay [via Runtime Revolution] wrote:
> On 11/4/10 7:55 PM, charles61 wrote:
>
> > When I of marked card y, the script that looks like the following
> > caused the printing to hang and I had to force quit Rev 4.0 and
> > relaunch Rev.
>
> This, plus the recursion error you got, likely indicates that your
> scripts are going in circles without a way to complete. What does your
> "mouseUp" handler do exactly? If it calls a different handler, which in
> turn calls the mouseUp again, then your script will loop between the two
> handlers until eventually you get the error, or it looks like you hung.
> (Did you try command-period to stop the scripts?)
>
> Usually it's better not to call system messages if possible. Instead of
> sending a mouseup to a button, send a custom handler name instead. Then
> have your mouseUp handler call that same custom handler. For example, if
> you have this:
>
> on mouseUp
> commandOne
> commandTwo
> end mouseUp
>
> Instead, do this:
>
> on mouseUp
> doStuff
> end mouseUp
>
> on doStuff
> commandOne
> commandTwo
> end doStuff
>
> Now your looping reset script can send "doStuff" to each button instead
> of sending "mouseUp" to it. In fact, all your handlers that need to do
> the mouseUp button stuff should be sending "doStuff" instead.
>
>
> --
> Jacqueline Landman Gay | [hidden email]
> HyperActive Software | http://www.hyperactivesw.com
> _______________________________________________
> use-revolution mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution
>
>
> View message @ http://runtime-revolution.278305.n4.nabble.com/What-is-wrong-with-this-script-tp3027821p3028051.html
> To unsubscribe from What is wrong with this script?, click here.
>
--
View this message in context: http://runtime-revolution.278305.n4.nabble.com/What-is-wrong-with-this-script-tp3027821p3028076.html
Sent from the Revolution - User mailing list archive at Nabble.com.
More information about the use-livecode
mailing list