In a batch file you can use %PROGRAMFILES% to get the location of the program files directory, how do you do it in a VBScript?
+4
A:
Set wshShell = CreateObject("WScript.Shell")
WScript.Echo wshShell.ExpandEnvironmentStrings("%PROGRAMFILES%")
Jonas Elfström
2009-12-11 22:32:59
Nice, thanks. I have been resorting to reading the registry, but your answer is far better. Thanks.
Jeremy
2009-12-12 18:05:16