Enumerating the drives on my computer

  • Thread starter Thread starter Simon Harvey
  • Start date Start date
S

Simon Harvey

Hi everyone,

What would be the easiest way to identify what drives my local machine has
access to. This includes Cd, DVD, floppy, network and local drives.

I need to add these directories to a treeview. Very standard stuff, but I
don't know how to enummerate the drives.

Many thanks to anyone who can help

Simon
 
System.Environment.GetLogicalDrives

Return Value
An array of string where each element contains the name of a logical drive.
For example, if the computer's hard drive is the first logical drive, the
first element returned is "C:\".
 
Back
Top