Variables inside handlers
Variables inside handlers
- Subject: Variables inside handlers
- From: The Other Rob <email@hidden>
- Date: Wed, 11 Dec 2002 15:48:41 +1100
Thanks to the help of some generous people on this list, I've worked out the
following bits of scripting.
This script launches my script application called test3app:
ignoring application responses
launch application "OSX:test3app"
run application "OSX:test3app"
tell application "OSX:test3app" to somehandler("$1", "$2", "$3")
end ignoring
And this is the relevant code from test3app:
on somehandler(test1, test2, test3)
-- various lines that do stuff with test1, test2, test3
end somehandler
My problem is that the scope of the variables (test1, test2, test3) is
limited to that particular handler, and I can't access them from other parts
of my test3app script. Is there any way to make these variables available
to the rest of my script?
I've read some Apple documentation which discuss the scope of variables
inside handlers, but it just gives details of the scope. I've also read
some archives from this list without any luck, but I did come across an
amusing thread from March of this year discussing something similar. I'm
sure some of you remember it. :)
Regards,
-Rob
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.