How to delete the volume of dynamic disk?

Hi all,
I created a virtual dynamic disk by employing a scsi miniport driver and a
private bus driver.
After I stoped my virtual disk device, I could see in WinObj that my virtual
disk device object was deleted. But the volume object relevanted to my
virtual device object still existed. Therefore, I could still see the drive
letter in explore.
My question is how to delete the volume object when I stop my virtual disk
object?
I know that Diskpart can do the job. But is there any other way of sending
some IOCTLs?
Thanks in advance.
Shell

How did you stop your virtual disk? If you want a controlled removal you
should be unmounting volumes and then removing the disk. Also if you think
your disk ought to function like removalbe media you ought to indicate that
it is removable media. The volume manager api in the platform sdk includes
interfaces for unmounting volumes.

=====================
Mark Roddy DDK MVP
Windows 2003/XP/2000 Consulting
Hollis Technology Solutions 603-321-1032
www.hollistech.com


From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of jason shell
Sent: Friday, November 04, 2005 4:25 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] How to delete the volume of dynamic disk?

Hi all,
I created a virtual dynamic disk by employing a scsi miniport driver and a
private bus driver.
After I stoped my virtual disk device, I could see in WinObj that my virtual
disk device object was deleted. But the volume object relevanted to my
virtual device object still existed. Therefore, I could still see the drive
letter in explore.
My question is how to delete the volume object when I stop my virtual disk
object?
I know that Diskpart can do the job. But is there any other way of sending
some IOCTLs?
Thanks in advance.

Shell
— Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256 You are currently subscribed to
ntdev as: unknown lmsubst tag argument: ‘’ To unsubscribe send a blank email
to xxxxx@lists.osr.com

Emulate PnP removal of the disk in your private bus driver.

Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com

----- Original Message -----
From: “jason shell”
To: “Windows System Software Devs Interest List”
Sent: Friday, November 04, 2005 12:24 PM
Subject: [ntdev] How to delete the volume of dynamic disk?

Hi all,
I created a virtual dynamic disk by employing a scsi miniport driver and a
private bus driver.
After I stoped my virtual disk device, I could see in WinObj that my virtual
disk device object was deleted. But the volume object relevanted to my
virtual device object still existed. Therefore, I could still see the drive
letter in explore.
My question is how to delete the volume object when I stop my virtual disk
object?
I know that Diskpart can do the job. But is there any other way of sending
some IOCTLs?
Thanks in advance.
Shell


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: unknown lmsubst tag argument: ‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com