WshShell.ExpandEnvironmentStrings

[This is preliminary documentation and subject to change.]

The ExpandEnvironmentStrings method expands the PROCESS environment variable in strString and returns the result string. Variables are enclosed by the '%' character.

The environment variable name is not case-sensitive.

Syntax

WshShell.ExpandEnvironmentStrings(strString) = strExpandedString
 

Example

MsgBox "Prompt is " & WshShell.ExpandEnviromentStrings("%PROMPT%")
 

© 1997 Microsoft Corporation. All rights reserved. Terms of Use.