How to: Determine a Drive's Root Directory in Visual Basic
The SecurityException exception.provides a object that can be queried for information about a drive on a computer. You can use the RootDirectory property to determine the root directory. Attempting to access the property without sufficient permission throws a
The options available in dialog boxes, and the names and locations of menu commands you see, might differ from what is described in Help, depending on your active settings or edition. This Help page was written with General Development Settings in mind. To change your settings, choose Import and Export Settings on the Tools menu. For more information, see.
To determine a drive's root directory
Use the RootDirectory property to determine the root directory, as illustrated in the following code.