I need to be able to set a session based environment variable for an application to run properly.
This fails with a cannot find file error. I assume this is because of the SET ... && ... (trying to run 2 commands from one command line input.
Can someone help me here? It needs to be done as a session only variable because using the "USER" of "SYSTEM" setting causes problems with our support staff because the envionment variable set at that level makes it so they cannot deal with multiple open sessions set to different banks.
Thanks
Thanks
John Fuhrman
Titan Global Services
faq329-6766
Code:
Dim objShell
set objShell = CreateObject("wscript.Shell")
sExePath = "E:\PROGRA~1\CoreDir\CORE_M~1\SYNERG~1\dbl\bin\dbr.exe"
sSwitches = "BIN:MNUMNU"
objShell.exec [red][b]"SET E:\PROGRA~1\CoreDir\Users\" & strUser & "\BK" & strBank[/b][/red] &_
" && " & Chr(34) & sExePath & Chr(34) & " " & sSwitches
This fails with a cannot find file error. I assume this is because of the SET ... && ... (trying to run 2 commands from one command line input.
Can someone help me here? It needs to be done as a session only variable because using the "USER" of "SYSTEM" setting causes problems with our support staff because the envionment variable set at that level makes it so they cannot deal with multiple open sessions set to different banks.
Thanks
Thanks
John Fuhrman
Titan Global Services
faq329-6766