<< Click to Display Table of Contents >> Navigation: OLE Automation > Application > Methods > SpaceObServer.Application.GetInformationByPath |
Description
Query file system information about the scanned directory with the passed directory path.
Syntax
GetInformation (Path : <String>, InfoType : <String>, UsePlainValues : <Boolean>, [out]NodeData : <OLEVariant>)
Parameters
Path |
The path to the folder, from which data should be extracted. |
InfoType |
Defines the kind of requested information about a directory. |
UsePlainValues |
Indicates, if size units and thousand separator will be included in the export, or if sizes are exported as plain values. |
[out]NodeData |
(Out Parameter) The delivered data. This is the place, to define a storing place for the returned data, you wanted to get. |
Example
PowerShell:
$RootFolderPath = "C:\"
$SOS.GetInformation($RootFolderPath, "Size", $False, $OutParameter)
VBS:
RootFolderPath = "C:\"
SOS.GetInformation RootFolderPath, "Size", False, OutParameter
The call of GetInformationByPath() gathers the size of the current root directory, and returns it in a OLEVariant variable called "OutParameter".
"OutParameter" can be accessed like every other variable of the variant type, and its content can be used for printing.