NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Directory.GetLogicalDrives

Retrieves the names of the logical drives on this machine in the form "C:\".

[Visual Basic]
Public Shared Function GetLogicalDrives() As String ()
[C#]
public static string[] GetLogicalDrives();
[C++]
public: static String* GetLogicalDrives() [];
[JScript]
public static function GetLogicalDrives() : String[];

Return Value

The logical drives on this machine.

Exceptions

Exception Type Condition
IOException An I/O error occurs (for example, a disk error).
SecurityException The caller does not have the required permission.
ArgumentException The directory name is empty or contains only whitespaces.

Requirements

NGWS Runtime Security:

SecurityPermission UnmanagedCode flag must be set to call unmanaged code, such as calling native code with PInvoke or COM Interop.

See Also

Directory Class | Directory Members | System.IO Namespace