VBScript works in Windows 7 64-bit Locks in XP WinSCP 5.0.5
Hi this code works fine on Win7 but not XP not sure if I am doing something wrong but what I get after I run it is a locked command line cursor blink and when I close the window it seems to finish up the script with WinSCP> so looks like its launching but not accepting the scripted params in XP, It also does not spit out a log.txt so there's nothing to help debug it and the script doesnt fail just locks with the blinking cursor.
Dim WshShell, OExec, output
' Setup Shell vars.
Set WshShell = WScript.CreateObject("WScript.Shell")
' Setup WinSCP and capture shell output.
Set oExec = WshShell.Exec("winscp.com /log=log.txt")
'test@ftp.lfpress.com
oExec.StdIn.Write(_
"option batch abort" & vbCRLF & _
"option exclude ""*/; .DS_Store; *.ini; *.tmp; *.mp4>300M; *.avi>300M; *.mpg>300M""" + vbCRLF & _
"open X@X.X.com" + vbCRLF & _
"synchronize local -delete ""ScreenUpload\"" ""/en/""" + vbCRLF & _
"exit" + vbCRLF)
' wait until it finishes and collect its output.
output = oExec.StdOut.ReadAll()
' print the output.
WScript.Echo(output)