Re: set variable to a command?
Re: set variable to a command?
- Subject: Re: set variable to a command?
- From: Steve Mills <email@hidden>
- Date: Wed, 19 Nov 2003 12:09:41 -0600
On Nov 19, 2003, at 11:06, David A. Cox wrote:
This does not:
set command to "play"
tell application "iTunes"
command
end tell
You can't do that. The line 'set command to "play"' is setting the
variable "command" to the string "play", which has nothing to do with
the verb "play". I just tried forcing the 4-char code into a variable,
but that doesn't work either. You'll probably just have to set command
to your own strings (possibly even "play" and whatever other commands
you want to do), then switch off those strings to the actual verbs:
set command to "play"
tell app "iTunes"
if command is "play" then
play
else if command is "pause" then
pause
end if
end tell
Steve Mills
Drummer, Mac geek
http://sjmills5.home.mchsi.com/
_______________________________________________
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.