Hiding programs

Joined
Oct 4, 2006
Messages
26
Reaction score
0
Points
1
Location
Vancouver, BC
Your Mac's Specs
iMac 20" 2.16Ghz Intel Duo Core 2
Hi All,
I have just taken the plunge into mac land so expect a lot of questions from me in the near future.
My first one is , is there a way of opening and hiding programs at the same time automatically on start up e.g. Mail and Itunes .

Thanks
 
Joined
Sep 21, 2005
Messages
809
Reaction score
111
Points
43
Location
ohio
Your Mac's Specs
iBook G4 OSX Tiger
In System Preferences, under Accounts, you can choose Login Items that will load when your computer starts up. It also has the option to Hide it. When I put mail in my login items and selected hide, it didn't. So I wrote an applescript that will open it and close the top window and put that in my login items instead. I don't see why it wouldn't work for iTunes too. Here's the code:
Code:
tell application "Mail" to activate
tell application "Mail" to close the front window

tell application "iTunes" to activate
tell application "iTunes" to close the front window

Just copy it into an applescript, then add that to your login items

login.png
 
OP
M
Joined
Oct 4, 2006
Messages
26
Reaction score
0
Points
1
Location
Vancouver, BC
Your Mac's Specs
iMac 20" 2.16Ghz Intel Duo Core 2
I tried the above in applescript editor when I pressed run it came up with an error message and highlited "to close front window".
Its probably something I've done wrong my little brain is still in windows mode. :p
 
Joined
Sep 21, 2005
Messages
809
Reaction score
111
Points
43
Location
ohio
Your Mac's Specs
iBook G4 OSX Tiger
maccsyd said:
I tried the above in applescript editor when I pressed run it came up with an error message and highlited "to close front window".
Its probably something I've done wrong my little brain is still in windows mode. :p
Thats because the application is running but you have no windows open. It should work when you put it in your login items because the "activate" command will open the app with a window.

I don't know if I explained that well enough but if you want to test it, completely close the apps first. Then when you run it, it will open the apps and close the top window just like it will on login
 
Joined
Aug 27, 2005
Messages
2,406
Reaction score
210
Points
63
Location
Fayetteville, AR
Your Mac's Specs
15" Powerbook G4 • 24" iMac • iPhone 3Gs
You could just open System Preferences, go to Accounts, click "Login Items", then click the + sign to add the application, then click the "Hide" button.
 
Joined
Sep 21, 2005
Messages
809
Reaction score
111
Points
43
Location
ohio
Your Mac's Specs
iBook G4 OSX Tiger
surfwax95 said:
You could just open System Preferences, go to Accounts, click "Login Items", then click the + sign to add the application, then click the "Hide" button.
I mentioned that, but when I did it that way, Mail wouldn't hide. I wanted it to hide so I had to write a script to do it for me. (Quicksilver had the same issue a while back here)
 
Joined
Aug 27, 2005
Messages
2,406
Reaction score
210
Points
63
Location
Fayetteville, AR
Your Mac's Specs
15" Powerbook G4 • 24" iMac • iPhone 3Gs
Ah, my bad, just saw the Applescript stuff. :)
 
OP
M
Joined
Oct 4, 2006
Messages
26
Reaction score
0
Points
1
Location
Vancouver, BC
Your Mac's Specs
iMac 20" 2.16Ghz Intel Duo Core 2
Thanks for the help I finally got it to work when I realised it wasn't saving it as an application file :eek:)
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top