Auto mount network drives with delay AppleScript
Hi folks.
I'm a newbie to AppleScript.. but I'm currently using an AppleScript application to auto mount a number of network volumes from my NAS when I login to my macbook. (found this solution here: https://discussions.apple.com/thread/3205868?answerId=15795774022#15795774022 )
The script i'm using is as follows.
-- Automatically mount network drives
try
mount volume "afp://192.168.1.100/video" as user name "admin" with password "*************"
end try
try
mount volume "afp://192.168.1.100/photo" as user name "admin" with password "*************"
end tryI've saved this as an application and added it to my Login items list.
However, the application tries to run before my wifi network has kicked in so fails a lot of the time.
Is there any way to add a delay of around 60 seconds before the application tries to mount?
An even better solution would be to test if there is an available network connection before running the rest of the script.
Please help.
MacBook Pro (Retina, 15-inch, Late 2013), OS X Mavericks (10.9.3)