Post a reply

Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)


Topic review


Thanks for your answer but the problem is that I don't know the script to play in advance.
The scripts are generated dynamically by the actions of the users on another application.

I see the first WinScp session in the taskbar (if I don't use exit on my script), isn't it possible to call this session?

Something like WinScp.exe /useAlreadyOpenedConnexion 1 /console /command /script=C:\Test\next_command.txt

Re: Use opened session with different scripts

You have to merge the scripts into one and make the script pause somehow between the two phases.
You can try something like "call sleep 5m" (if you use SFTP/SCP).

Use opened session with different scripts


I'm facing some problem to use an opened session on an unix server. We use a securID so the password changes every minute.

How is it possible to run several scripts for the same session but not at the same time?

For exemple :

Batch file :
WinScp.exe MyUnixServer /console /command /script=C:\Test\send_file_1.txt

Scripts files :
send_file_1.txt :
option transfer binary
put C:\Test\my_file_1.txt /home/test/my_file_1.txt

send_file_2.txt :
option transfer binary
put C:\Test\my_file_2.txt /home/test/my_file_2.txt

Batch file is run (enters for the first time the password) and some minutes later we have to run the second script file. How to use the first session opened?