The real command:
C:\myprogram\foo.exe -tnet -proxyproxy.txt -uusr.lem.upt:demo
"includes parameters and username password.
Dim objShell
Dim objWsh
Dim wshshell
Set objWsh = CreateObject("Wscript.Shell")
Set objShell = CreateObject ("WScript.Shell")
Const username = "HKEY_CURRENT_USER\myprogram\someregkey\username"
Const password = "HKEY_CURRENT_USER\myprogram\someregkey\password"
Set wshshell = WScript.CreateObject ("WScript.Shell")
results = WShShell.RegRead ("HKEY_CURRENT_USER\myprogram\someregkey\username")
WScript.Echo results
Set WshShell = WScript.CreateObject ("WScript.Shell")
results = WShShell.RegRead("HKEY_CURRENT_USER\myprogram\someregkey\password")
WScript.Echo results
cmdline = cmdline = """c:\program files\myprogram\foo.exe"" -rite -proxy.txt -" & username & ",.lem" ":" & password & "upt,"
WScript.echo cmdline
objWsh.run cmdline,1,False
I am trying to take the regread from the username password regkeys and drop them into the appropriate spot in the .vbs script - but falling short in dropping in the username/password correctly. I think I am on the right track, but could use a hand.
Thanks!
C:\myprogram\foo.exe -tnet -proxyproxy.txt -uusr.lem.upt:demo
"includes parameters and username password.
Dim objShell
Dim objWsh
Dim wshshell
Set objWsh = CreateObject("Wscript.Shell")
Set objShell = CreateObject ("WScript.Shell")
Const username = "HKEY_CURRENT_USER\myprogram\someregkey\username"
Const password = "HKEY_CURRENT_USER\myprogram\someregkey\password"
Set wshshell = WScript.CreateObject ("WScript.Shell")
results = WShShell.RegRead ("HKEY_CURRENT_USER\myprogram\someregkey\username")
WScript.Echo results
Set WshShell = WScript.CreateObject ("WScript.Shell")
results = WShShell.RegRead("HKEY_CURRENT_USER\myprogram\someregkey\password")
WScript.Echo results
cmdline = cmdline = """c:\program files\myprogram\foo.exe"" -rite -proxy.txt -" & username & ",.lem" ":" & password & "upt,"
WScript.echo cmdline
objWsh.run cmdline,1,False
I am trying to take the regread from the username password regkeys and drop them into the appropriate spot in the .vbs script - but falling short in dropping in the username/password correctly. I think I am on the right track, but could use a hand.
Thanks!