TechNet
Export (0) Print
Expand All
Collapse the table of content
Expand the table of content
Expand Minimize

Converting the FileSystemObject's IsReady Property


Windows PowerShell


Definition: Returns True if the specified drive is ready.

IsReady


Use the IsReady property of the .NET Framework DriveInfo object:


$d = New-Object -typename System.IO.DriveInfo -argumentlist "C:"
$d.IsReady


Here we’ve created an instance of the DriveInfo class, passing the argument C: to create an instance referencing the C: drive. We then simply check the IsReady property.


See conversions of other FileSystemObject methods and properties.
Return to the VBScript to Windows PowerShell home page

Show:
© 2016 Microsoft