Re: Help with Script to mount SMB
Re: Help with Script to mount SMB
- Subject: Re: Help with Script to mount SMB
- From: Jim Weisbin <email@hidden>
- Date: Wed, 14 Oct 2015 08:09:53 -0400
"Ball, Dan" <email@hidden> wrote:Hoping someone can help with this script? I have a small xcode app I made years ago that gives users a GUI to mount shares off of our servers. I opened it up here just to make some small changes and I’m noticing the on error part not working anymore. I know this used to work, but not sure when it stopped. Script: tell application "Finder" try mount volume " smb://server.apple.com/share" on error tell application "Finder" activate display dialog "I cannot locate share or you already have it mounted!" buttons {"Cancel"} default button "Cancel" with icon caution giving up after 10 end tell end try end tell
I understand that you would want it to throw an error if it can’t connect (which I assume it does).
What I don’t understand is why you care if it’s already mounted. If it’s already mounted, your code won’t error and as far as I can see no bad consequences - the system won’t mount it “twice”.
Jim Weisbin | C.T.O. | human
|
_______________________________________________
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