Re: Running Subroutines from Other Scripts
Re: Running Subroutines from Other Scripts
- Subject: Re: Running Subroutines from Other Scripts
- From: Andy Wylie <email@hidden>
- Date: Sat, 24 Aug 2002 09:06:31 +1200
on Fri, 23 Aug 2002 14:11:50 -0400 Adam Backstrom wrote:
>
Hey everyone,
>
>
I'm working on a series of AppleScripts written in AppleScript Studio.
>
For the sake of organization, I would like to split up the code into
>
several scripts. The problem is, I can't find the correct syntax for
>
telling an outside script to run a subroutine. Is this functionality
>
supported?
>
I don't know about AS Studio or X but this works here...
--master
run script (choose file) with parameters {1, "woo"}
--slave
on run (params)
if params's item 1 = 1 then sayit(params's item 2)
end run
on sayit(blah)
say blah
end sayit
--most people seem to use 'load script'...
set x to load script (choose file)
tell x to sayit("woo")
_____________________________ Andy
_______________________________________________
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.