Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Developer Center > Open Front Row With Currently Playing iTunes Song

Open Front Row With Currently Playing iTunes Song
Thread Tools
ncmason
Guest
Status:
Reply With Quote
Feb 27, 2007, 08:49 AM
 
I have set up a simple iTunes script where iTunes will open up and play my main library. I would like to make Front Row open up with the currently playing song. Any suggestions on an Applescript to make this work?
( Last edited by ncmason; Feb 27, 2007 at 05:37 PM. )
     
Diggory Laycock
Professional Poster
Join Date: Oct 2001
Location: London
Status: Offline
Reply With Quote
Feb 28, 2007, 07:26 AM
 
requires 'enable access for assistive devices' checkbox to be ticked in the 'Universal Access' pref pane.


[codex]
tell application "System Events"

-- Command Esc. to start Front Row
key code 53 using command down

-- wait for Front Row to be ready for keyboard input
delay 4

-- Press Return twice (Music -> currently playing)
key code 36
key code 36
end tell
[/codex]
     
Diggory Laycock
Professional Poster
Join Date: Oct 2001
Location: London
Status: Offline
Reply With Quote
Feb 28, 2007, 07:39 AM
 
     
ncmason
Guest
Status:
Reply With Quote
Feb 28, 2007, 04:39 PM
 
Hey, thanks so much for the feedback.

Here is my script that I made:

tell application "iTunes"
play playlist "music"
end tell

How exactly do I apply the script you made with mine?

Thanks,
Mason
     
Diggory Laycock
Professional Poster
Join Date: Oct 2001
Location: London
Status: Offline
Reply With Quote
Feb 28, 2007, 06:12 PM
 
If I understand correctly what you want, then you just need to put your part of the script first then mine:
e.g.
[codex]
tell application "iTunes"
play playlist "music"
end tell

tell application "System Events"
-- Command Esc. to start Front Row
key code 53 using command down
-- wait for Front Row to be ready for keyboard input
delay 4
-- Press Return twice (Music -> currently playing)
key code 36
key code 36
end tell
[/codex]
     
ncmason
Guest
Status:
Reply With Quote
Feb 28, 2007, 06:59 PM
 
Thank you so much. I couldn't have done this script without you. Thanks again.
     
   
 
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Top
Privacy Policy
All times are GMT -4. The time now is 07:37 PM.
All contents of these forums © 1995-2017 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2017, Jelsoft Enterprises Ltd.,