Mac Help Forums


Reply
Thread Tools Display Modes

AppleScript Help needed...

 
Member
Join Date: Oct 2006
Posts: 5
 
      6th October 2006
Apologies if this is an area that's been covered before.

I work in a graphic design studio with an Xserve as our main server and a number of G5s and newer Intel iMacs. I want to create a quick applescript to connect to the server automatically when I start my machine in the morning, and then customise it so that everyone else in the studio can have it on their machine as well.

I've had a quick poke around with the Script Editor but quite quickly got stuck.

Thanks!

sketch
 
Reply With Quote
 
 
 
 
Senior Member
zeyhra's Avatar
Join Date: Mar 2006
Location: Santa Cruz, California
Posts: 198
 
      6th October 2006
I've got the same kind of thing running at my office. We have 4 different volumes that all need to be mounted on startup... It's a fairly simple Applescript... I have all my users have it as a start up item and also keep it in their dock in case of disconnects.

tell application "Finder"
mount volume "afp://username:password@IPaddress/volumename"
end tell

just open script editor, copy and paste this into it, and fill in your specific info
Then compile it and save as an application.
 
Reply With Quote
 
Ric Ric is offline
Senior Member
Ric's Avatar
Join Date: May 2004
Posts: 4,260
 
      6th October 2006
Hi all,

you can also make an alias of the Server and then add it into the login items on each Mac.

Mount each volume...Then open System Prefs-->Accounts and drag the disk icon to the Login items pane...



regards

Ric
 
Reply With Quote
 
Senior Member
Danster's Avatar
Join Date: Feb 2005
Location: Liverpool, England
Posts: 267
 
      6th October 2006
I don't know if connecting to an in-house server is different from connecting to your standard ISP host, but when I start my computer it auto-connects due to start up items such as mail.

You can configure this from the PPP options in systempref/network
Attached Thumbnails
AppleScript Help needed...-picture-1.jpg  

 
 
Reply With Quote
 
Senior Member
zeyhra's Avatar
Join Date: Mar 2006
Location: Santa Cruz, California
Posts: 198
 
      7th October 2006
Sure, you could make it a startup/login item, but what's the fun in that!?

I'd originally set up all our machines at the office with the servers as startup items, but we had several weirdnesses occur that convinced me to set them up differently. (We connect to our local servers via TCP/IP.)

1-Start up items would "forget" what the drives were (as in "kind" would be "unknown") and would therefore not connect on start up.

2-Connections to the server would be dropped and under "Connect to Server" in the "Go" menu, the servers we'd need to connect to were grayed out, which is how they would look when you're already connected.

These problems could very well be a symptom of a different problem on our network, but for us, the Applescript solution works quite well, and in fact is the only thing that works consistently on all the computers.
 
Reply With Quote
 
Ric Ric is offline
Senior Member
Ric's Avatar
Join Date: May 2004
Posts: 4,260
 
      7th October 2006
I know what you mean ;-)

The login items is a bit hit and miss sometimes, I'm sure the AppleScript is the best bet.

regards

Ric
 
Reply With Quote
 
Member
Join Date: Oct 2006
Posts: 5
 
      9th October 2006
thanks zeyhra - I'll give it a whirl and see what happens.
 
Reply With Quote
 
Member
Join Date: Oct 2006
Posts: 5
 
      9th October 2006
seems to work perfectly - have to hit enter a couple of times but at least I won't forget to connect to the server.
 
Reply With Quote
 
Member
Join Date: Oct 2006
Posts: 5
 
      9th October 2006
hmmm - I put it in the startup items folder but it doesn't seem to be running when I restart the machine... all I've done is dragged 'n' dropped it into the folder - is there something else I need to do?
 
Reply With Quote
 
Ric Ric is offline
Senior Member
Ric's Avatar
Join Date: May 2004
Posts: 4,260
 
      10th October 2006
Hi there,

Instead of putting it into the startup items folder...go to system prefs-->accounts and add it into the login items.

regards

Ric
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting 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
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
AppleScript Language Guide for AppleScript 2.0 Patrick Stadelmann AppleScript 0 12th March 2008 05:00 PM
Help needed with Applescript to send text to textedit Si UK Macs 5 30th January 2006 07:26 AM
Experienced Applescript Expert Needed Scott AppleScript 2 29th August 2005 07:50 PM
Font needed - advice needed!! Duncan Langford Printing 1 4th December 2004 12:49 AM
Applescript & Exposé - Help Needed. Strange Attractor AppleScript 8 11th November 2004 05:01 AM


All times are GMT +1. The time now is 04:16 AM.
Mac-Help.com is an independent website and is not affiliated with Apple Inc.


Welcome!
Welcome to the Mac Help Forums
 


Latest Threads
Help! Stupid computer is automatically logging me out
Elizaboo (5 Hours Ago, 10:41 PM)

URGENT Help. Crazy talk Mac!
Joeker (6 Hours Ago, 09:42 PM)

PDF Document
yura (16 Hours Ago, 12:13 PM)

Difficulties with internet speed (nothing to do with connection)
sammethh (21 Hours Ago, 06:36 AM)

Deleting a homepage/website form my mac book pro
rgandajg (1 Day Ago, 10:30 PM)

 


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51