Posted: 2008-08-14 15:12
i want to use System-Environment-Variables in my script-file like this:
winscp.exe /console /script=ftp.txt
option batch on
option confirm off
# Change remote directory
# Force binary mode transfer
option transfer binary
# Upload file
put update.log %COMPUTERNAME%.log
# Exit WinSCP
The upload went fine, but the remote-filename is not like expected myhostname.txt but %COMPUTERNAME%.txt so the variable is not translated.
What went wrong?
Posted: 2008-08-15 14:37
Sorry, forget to mention.
Running WinSCP 4.0.7 on Windows Server 2003.
Posted: 2008-08-15 14:50
After updating to 4.1.6 the problem is solved. The environment-variable is now translated.
You can post new topics in this forum
And it's free!