pdisknum (PULONG) - output
The value 1 means drive A, 2 means drive B, 3 means drive C, and so on. The maximum possible value is 26, which corresponds to drive Z.
plogical (PULONG) - output
This bit map is stored in the low-order portion of the 32-bit area.
Logical drives A to Z have one-to-one mapping with bit positions 0 to 25 of the map; for example, bit 0 represents drive A, bit 1 represents drive B, and so on. The settings of these bits indicate which drives exist, as follows:
ulrc (APIRET) - returns
DosQueryCurrentDisk returns the following value:
For a full list of error codes, see Errors.