Re: Unmounting a volume
Re: Unmounting a volume
- Subject: Re: Unmounting a volume
- From: Luther Fuller <email@hidden>
- Date: Mon, 23 Feb 2015 08:43:56 -0600
On Feb 22, 2015, at 11:00 PM, Dave C wrote: I want to unmount a volume, one of 2 on a hard drive. I have successfully unmounted the drive but, of course, this unmounts both volumes:
do shell script "diskutil unmountDisk " & diskDev
How can I unmount just one volume?
I just looked at some of my code and I used the Finder to unmount a volume.
set diskAlias to my mountImageDisk(dropItem) if not my TrashIsEmpty(diskAlias) then .... end if tell application "Finder" to eject diskAlias
The 'mountImageDisk' handler returns an alias to the mounted disk like this ...
set diskAlias to (POSIX file volName) as alias return diskAlias -- an alias to the disk mounted from the disk image file
Does this work for any disk, not just for disks mounted from a disk image file ? It ought to. Let us know.
|
_______________________________________________
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