Re: Script Objects in Libraries
Re: Script Objects in Libraries
- Subject: Re: Script Objects in Libraries
- From: Jason Bourque <email@hidden>
- Date: Thu, 08 Jul 2004 21:41:22 -0400
Hans,
That did the trick. Thanks again.
Jason Bourque
On 7/8/04 4:58 PM, "Hans Haesler" <email@hidden> wrote:
>
On Thu, 08 Jul 2004, Jason Bourque wrote:
>
>
> I have a QuarkXPress handler in a library that that calls
>
> a script object in that same library. I get an error every time.
>
> -->> Error: The variable checkSpreads is not defined.
>
>
Hello Jason,
>
>
a script object must be defined _before_ it is called
>
from a handler. Just switch the order:
>
---
>
script checkSpreads
>
display dialog "Success"
>
end script
>
>
tell me to srhandler()
>
>
on srhandler()
>
tell application "QuarkXPress 6.1"
>
activate
>
do script {checkSpreads}
>
end tell
>
end srhandler
>
---
>
The 'activate' makes sure that the dialog is shown
>
in front.
>
>
Regards,
>
Hans
>
>
---
>
Hans Haesler <email@hidden>
>
_______________________________________________
>
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.
_______________________________________________
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.