Get current Drive : Drive « Stream File « VB.Net Tutorial






Option Strict On

Public Module CurDriveFunction
   Public Sub Main()
      Console.WriteLine("The current drive is {0}.", Left(CurDir(), 1))
   End Sub

End Module
The current drive is C.








13.15.Drive
13.15.1.Get current Drive
13.15.2.Get Logical drives
13.15.3.DriveInfo: Name, IsReady, DriveType, RootDirectory
13.15.4.DriveInfo: AvaiableFreeSpace, DriveFormat, TotalFreeSpace, VolumnLabel
13.15.5.DriveInfo.GetDrives