Пример #1
0
 private void OnDriveUnavailable(DriveUnavailableEventArgs e)
 {
     if (DriveUnavailable != null)
     {
         DriveUnavailable(this, e);
     }
 }
Пример #2
0
 private bool CheckDriveExists(string driveLetter)
 {
     if (driveLetter != "\\")
     {
         var di = new DriveInfo(driveLetter);
         if (!di.IsReady)
         {
             var e = new DriveUnavailableEventArgs(driveLetter, di.DriveType);
             OnDriveUnavailable(e);
             return(false);
         }
     }
     return(true);
 }