SWbemObjectPath. RelPath, propriété
La propriété RelPath de l’objet SWbemObjectPath contient le chemin d’accès relatif à partir du chemin d’accès complet.
Pour une explication de cette syntaxe, consultez conventions de document pour l’API de script.
Cette propriété est en lecture/écriture.
Syntaxe
SWbemObjectPath.Relpath As String
Valeur de la propriété
Exemples
L’exemple de code VBScript suivant illustre la différence entre les données obtenues à partir de SWbemObject. Path _ et 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
Spécifications
| Condition requise | Valeur |
|---|---|
| Client minimal pris en charge |
Windows Vista |
| Serveur minimal pris en charge |
Windows Server 2008 |
| En-tête |
|
| Bibliothèque de types |
|
| DLL |
|
| CLSID |
CLSID _ SWbemObjectPath |
| IID |
IID _ ISWbemObjectPath |