Re: iTunes script problems
Re: iTunes script problems
- Subject: Re: iTunes script problems
- From: Matthew Smith <email@hidden>
- Date: Fri, 20 Nov 2009 18:50:26 +1100
It sounds to me that option 2 is more what you want.
Have you ever used iTunes DJ? You could set iTunes DJ to play from an empty playlist. I doubt this part is possible from AppleScript. You could then add your list of songs to the iTunes DJ playlist, not the source playlist. This way you won't have to deal with extra playlists. Any new searches you do will then just add the songs to the currently playing list.
You could still do option 1. You can do it with one specific playlist that you empty, refill with your search results, and then play, but this will stop any currently playing song if it is in that playlist.
This where an iPhone or an iPod Touch is handy. The Remote app gives you a lot of control over iTunes.
--
Matthew Smith
On Friday, November 20, 2009, at 05:50PM, "Chuck" <email@hidden> wrote:
>
I was hoping that I could get by without creating a million playlists.
Maybe if I could get AS to create a playlist, put the songs I want in there, play those songs, then delete the playlist when I am done.
I have over 5000 songs with probably 3000 artists.
I will look onto seeing if I can make the first one work.
My overall goal is to send a text to Mail and have it tell iTunes what to play. I already have playlists controlled by a wireless remote but there is only 20 total that I can choose from. My cell phone would all me to type in whatever artist I want to hear and have it play.
Chuck
On Nov 19, 2009, at 10:11 PM, Matthew Smith wrote:
Hi,
You can't make iTunes play an arbitary list of songs via AppleScript. You need to make that a list of songs somewhere in the iTunes interface first and then play that list. There are several ways you may be able to do this. I am not sure if they are all possible with AppleScript. I'm not on my Mac right now.
1. Create a new playlist containing those songs.
2. Add the songs to iTunes DJ and play them there.
3. Display the playlist in the window, do a query to reduce the list to the desired songs and then play them. This one is not advisable as it won't work if the user changes what is displayed in iTunes.
Your best option I think is the first one, where you can have a specific playlist for your result. This one is definitely scriptable.
--
Matthew Smith
Almost there.
It plays one song and then goes back to other songs (I have it on shuffle). I am trying to get it to select just one group and play only their music.
At least this plays one song of the group I requested.
Chuck
I think you want something like this:
tell application "iTunes"
set myTunes to get search playlist "Saddest Songs Ever" for "Nilsson"
repeat with thisTune in myTunes
play thisTune
end repeat
end tell
The search returns a list, of songs, even if it's just one, so you can either step through the list or play item 1 of the list:
HTH,
ES
On Nov 19, 2009, at 3:45pm, Chuck wrote:
tell application "iTunes"
get search playlist "Get er done P1OFF" for "Moody Blues"
end tell
_______________________________________________
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
_______________________________________________
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