Hello!
You should try this:
The ExpandEnvironmentStrings
method can expand environment variables embedded in a string too:
Set wshShell = CreateObject( "WScript.Shell" )
WScript.Echo wshShell.ExpandEnvironmentStrings( "PATH=%PATH%" )
wshShell = Nothing
The output will look like this (but probably longer):
PATH=C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem