(no subject)
(no subject)
- Subject: (no subject)
- From: Ed Stockly <email@hidden>
- Date: Mon, 21 Apr 2008 07:06:54 -0700
On Apr 20, 2008, at 6:37 PM, Gil Dawson wrote:
What is the syntax for "some", as in...
tell application "iTunes"
tell playlist "ClodiFon"
name of some track whose (database ID) is dbid
end tell
end tell
I couldn't find it in my copy of The AppleScript Language Guide
(1996 edition).
Some will return a random item from an appleScript list.
tell application "iTunes"
tell playlist "ClodiFon"
set allMyTracks to name of every track whose (database
ID) is dbid
set thisTrack to some item of allMyTracks
end tell
end tell
But, that doesn't make much sense, since database ids are unique. You
may want:
set thisTrack to name of track 1 whose (database ID)
is dbid
or
set allMyTracks to name of every track
set thisTrack to some item of allMyTracks
I couldn't find it in my copy of The AppleScript Language Guide
(1996 edition).
There is a 2008 edition now available.
Be sure to look for the some item command in the section on lists, I
think that where it is.
HTH,
ES
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden