Re: Passing local parameter to remote session
First, typically you want to execute a
See https://winscp.net/eng/docs/executables
You need to use
Though there's no point passing a value of an environment variable as parameter when you can resolve it directly in the command:
winscp.com
from a batch file, instead of winscp.exe
.
See https://winscp.net/eng/docs/executables
WinSCP.exe /console /parameter timestamp /command "open sftp://exchange:ut9k3cm0@10.213.114.3:22" "mkdir %1%"
You need to use
%timestamp%
syntax to make Windows expand the variable name.
Though there's no point passing a value of an environment variable as parameter when you can resolve it directly in the command:
WinSCP.com /command "open sftp://exchange:ut9k3cm0@10.213.114.3:22" "mkdir %timestamp%"