Itunes - persistent ids not unique (or, managing double integers)
Itunes - persistent ids not unique (or, managing double integers)
- Subject: Itunes - persistent ids not unique (or, managing double integers)
- From: Andrew Bush <email@hidden>
- Date: Sat, 11 Mar 2006 13:15:59 +1300
Hi all,
Ive got some applescript that is supposed to find a track, given its
persistent id.
looking at the persistent ids of all the tracks in the xml file
produced by itunes, they are all different - as expected, and appear to
be alphanumeric.
however running the code below finds every track in the library.
I assume this is because somehow the persistent id is somehow being
mangled or coerced into a different type.
Its type is listed as being double integer in the itunes dictionary.
I am running this applescript on 10.3.9 against the latest version of
itunes.
so, what am I doing wrong? any suggestions welcome.
tell application "iTunes"
tell playlist "Library1"
set t to track 1
set pid to (t's persistent ID)
-- display dialog (dbid as double integer)
set t to (every track whose persistent ID is pid)
repeat with this_track in t
display dialog (the name of this_track as string)
end repeat
end tell
end tell
yours cheerfully,
Andrew Bush
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden