home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   alt.msdos.batch.nt      Fun with Windows NT batch files      68,980 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 67,560 of 68,980   
   dr.j.r.stockton@gmail.com to Peter   
   Re: How to Test Whether a Drive Exists   
   06 Jun 20 10:49:46   
   
   On Saturday, 6 June 2020 14:29:07 UTC+1, Peter  wrote:   
   > Thanks for your reply!  I have not tried other DOS commands   
   > as you suggest because I am not familiar with CScript,   
   > VBScript or JScript so I don't know any of their commands,   
   > syntax or how to incorporate them in a batch file.  I would   
   > welcome any specific suggestions you may have that would   
   > determine whether a drive is 1) not connected vs. 2)   
   > connected but locked.   
      
   By "other DOS commands" I mean traditional ones that use input;   
   DIR, ATTRIB, COPY, MOVE, and perhaps more.  I do not expect a   
   useful result, but am not sure.   
      
   The code I posted earlier today, as Google Groups does not read   
   Microsoft's writing correctly, was broken in layout.  It should   
   have looked like this probably will :-   
      
   fso = new ActiveXObject("Scripting.FileSystemObject")   
      
   function Drive() { var D = fso.getDrive(   
       new Enumerator(fso.GetFolder(sFolder).Files).item().Drive ) ;   
     Rite("  Drive is " + sFolder + "\n" +   
       PaddIt(D.AvailableSpace, 16)	+ " AvailableSpace\n" +   
       PaddIt(D.DriveLetter, 16)		+ " DriveLetter\n" +   
       PaddIt(D.DriveType, 16)		+ " DriveType\n" +   
       PaddIt(D.FileSystem, 16)		+ " FileSystem\n" +   
       PaddIt(D.FreeSpace, 16)		+ " FreeSpace\n" +   
       PaddIt(D.IsReady, 16)		+ " IsReady\n" +   
       PaddIt(D.Path, 16)			+ " Path\n" +   
       PaddIt(D.SerialNumber, 16)		+ " SerialNumber\n" +   
       PaddIt(D.ShareName, 16)		+ " ShareName\n" +   
       PaddIt(D.TotalSize, 16)		+ " TotalSize\n" +   
       PaddIt(D.VolumeName, 16)		+ " VolumeName\n\n" ) }   
      
      
   function Drves() { var en, D, S = "  Drives :"   
     for (en = new Enumerator(fso.Drives) ; !en.atEnd() ; en.moveNext())   
       S += SP + en.item().DriveLetter ;   
     Rite(S + NL) }   
      
      
   You can see how to call CSCRIPT by looking in thread "Remove   
   all but digits" at my code for REGLARXP.BAT, which contains   
      
   @call CSCRIPT //nologo REGLARXP.JS %*   
      
   which just executes in CScript the JScript in REGLARXP.JS with   
   the arguments that were given to REGLARXP.BAT.   
      
   As far as I could see, however, there were only two ways to become   
   able to detect BITLOCKERing - (a) try all the likely commands in   
   the available languages (my previous suggestion), (b) locate the   
   BITLOCKER documentation or an expert, and ask - on the grounds   
   that I knew nothing of BITLOCKER or who its supplier might be   
   or where its documentation might be.   
      
   But I've just Googled BITLOCKER and discovered that it is part   
   of Windows 10; so I have it (but I don't want to run it).   
      
   From what Google found, it seems that you should (if not already   
   done) try entering 'manage-bde' and 'manage-bde -status' on the   
   command line of a partly BITLOCKERed PC ; if your answer is not   
   then obvious, try reading what Google found for me.   
      
   --   
     (c) John Stockton, near London, UK.  Using Google Groups.           |   
    Mail: J.R.""""""""@physics.org - or as Reply-To, if any.             |   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca