• 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: disconnect external volumes
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: disconnect external volumes


  • Subject: Re: disconnect external volumes
  • From: Matt Ray <email@hidden>
  • Date: Fri, 12 Apr 2002 14:39:53 -0500

JJ,

That works! Thank you very much!

I couldn't figure out how to determine the id of the startup disk other than running your script below.

Thanks,
Matt Ray



Question:
When the "list disks" command is used you get a list of your hardrive
name along with any disks that you have mounted including any servers
that you are connected to through a network.

Is there a way via AS to dismount or disconnect from all of these
except for your hardrive?


Answer:
Usually, your startup disk has ID -1 (ask the Finder about IDs).

-- not tested --
tell application "Finder"
eject (every disk whose id is not -1)
end tell
-----------
_______________________________________________
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.

References: 
 >Re: disconnect external volumes (From: JJ <email@hidden>)

  • Prev by Date: RE: filename/date validation [was: RE: applescript-users digest, Vol 3 #346 - 12 msgs]
  • Next by Date: 32k limit on Handle CGI Request bites!!!
  • Previous by thread: Re: disconnect external volumes
  • Next by thread: Re: disconnect external volumes
  • Index(es):
    • Date
    • Thread