Export (0) Print
Expand All

SWbemObject.Path_.Relpath property

The Relpath property of the SWbemObjectPath object contains the relative path from the complete path.

For an explanation of this syntax, see Document Conventions for the Scripting API.

This property is read/write.

Syntax


SWbemObject.Path_.Relpath As String

Property value

Examples

The following VBScript code example shows the difference between the data obtained from SWbemObject.Path_ and SWbemObjectPath.Relpath.


set objWMIService = GetObject ("winmgmts:root/cimv2")

set Processes = objWMIService.ExecQuery( _
    "Select * from win32_process")

For Each Process in Processes
 WScript.Echo Process.Path_ 
 WScript.Echo Process.Path_.Relpath
Next

Requirements

Minimum supported client

Windows Vista

Minimum supported server

Windows Server 2003

Type library

Wbemdisp.tlb

DLL

Wbemdisp.dll

 

 

Show:
© 2014 Microsoft