dougscripts.com

October 21 2015 - 4:21 pm

iTunes play with once is Broken Redux

I posted about this back in July but the problem seemed to go away (which is weird, too).

To play a track just once and then stop you use the once modifier with the play command:

tell application "iTunes"

set aTrack to item 1 of selection

play aTrack with once

end tell

As I said, I first noted this in July when iTunes 12.2 came out. But then I somehow couldn't get it not to work. Also saw a mention of it on the AppleScript mailing list, but even then I got it to work. Well, I definitely can't get it to work now. Filed a bug.

UPDATE: Ah-HA! It will work if the Up Next queue is completely empty, which can be made so by clicking its "Clear" button.

Site contents © 2001 - 2024 (that's right: 2001) Doug Adams and weblished by Doug Adams. Contact support AT dougscripts DOT com. About.
All rights reserved. Privacy.
AppleScript, iTunes, iPod, iPad, and iPhone are registered trademarks of Apple Inc. This site has no direct affiliation with Apple, Inc.
The one who says "it cannot be done" should not be interrupting the one who is doing it.