3.4.5.2.24.7 IVdsAdvancedDisk::DeleteDriveLetter (Opnum 9)

The DeleteDriveLetter method deletes a drive letter that is assigned to an OEM, ESP, or unknown partition.

 HRESULT DeleteDriveLetter(
   [in] ULONGLONG ullOffset,
   [in] WCHAR wcLetter
 );

ullOffset: The byte offset of the partition from the beginning of the disk. This offset MUST be the offset of a start of a partition.

wcLetter: The drive letter to delete as a single uppercase or lowercase alphabetical (A-Z) Unicode character.

Return Values: The method MUST return zero or a non-error HRESULT (as specified in [MS-ERREF]) to indicate success, or return an implementation-specific nonzero error code to indicate failure. For the HRESULT values predefined by the Virtual Disk Service Remote Protocol, see section 2.2.3.

When the server receives this message, it MUST validate the following parameters:

  • Verify that the partition at the byte offset that is specified by ullOffset does not have a volume existing on it.

  • Verify that the partition is using the drive letter specified by wcLetter.

The server MUST delete the drive letter from the partition and return an HRESULT indicating failure or success.