Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm using EnumNetworkDrives to list out all the drives on a machine. I'd like to determine which object in the collection is drive "X"

What object is returned in EnumNetworkDrives that has a property I can compare to a drive letter?

share|improve this question
add comment

1 Answer 1

up vote 2 down vote accepted

http://msdn.microsoft.com/en-us/library/t9zt39at(v=vs.85).aspx

The EnumNetworkDrives method returns a collection. This collection is an array that associates pairs of items — network drive local names and their associated UNC names. Even-numbered items in the collection represent local names of logical drives. Odd-numbered items represent the associated UNC share names. The first item in the collection is at index zero (0).

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.