• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Disk mounted
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Disk mounted


  • Subject: Re: Disk mounted
  • From: Tom Robinson <email@hidden>
  • Date: Tue, 15 Apr 2003 19:11:30 +1200

>I have a little script that performs different tasks on an USB disk.
>
>I would like the script to check if this USB disk is mounted and
>cancel (with an erros message) if it is not.

I wrote a script which checks for a .dmg being mounted, and if it isn't, mounts it. You should be able to adapt it:

tell application "Finder"
set mountedVolumes to name of disks
if mountedVolumes does not contain "nameofdisk" then open pathtodisk
-- Note script doesn't wait here for volume to be mounted
end tell

Cheers
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Finder can't find
  • Next by Date: Re: Finder can't find
  • Previous by thread: Re: Disk mounted
  • Next by thread: do shell script "system_profiler"
  • Index(es):
    • Date
    • Thread