[Help]: 'File permission error' setting track volume adjustment in iTunes
[Help]: 'File permission error' setting track volume adjustment in iTunes
- Subject: [Help]: 'File permission error' setting track volume adjustment in iTunes
- From: Jim Witte <email@hidden>
- Date: Sat, 2 Apr 2005 13:11:44 -0500
I've got the following script
tell application "iTunes"
try
set prevVol to sound volume
if playTunes is true then
activate
set sound volume to iTunesVol
set i to startVol
delay 5
play (playlist named tPlaylist)
repeat
set (volume adjustment of current track) to i
set i to i + trackVolInc
if (i > endVol) then exit repeat
delay rampDelay
end repeat
end if
-- reset volumes
tell application "iTunes"
set (volume adjustment of every track of playlist named tPlaylist) to 0 -- ***
set sound volume to prevVol
end tell
on error number -128
-- reset volumes
the error handle does the same setting of volumes as above, if I stop the script in script editor (I always run it from script editor). But when I run it, even if I select "No" in the dialog I thow up first (which sets playTunes to false), I get an error in the stared line "iTunes got an error: file permission error" iTunes is running now, and playing a song from the specified playlist. This also happens if I put the mac to sleep (closing it) instead of hitting stop - I was thinking that this didn't close some file needed when I close the mac).
This happens even if I close iTunes and start it up again, running the script immediately after opening it (not playing anything, and when playTunes is set to false).
Jim
_______________________________________________
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