WINSCRIPT file

Advertisement

ash
Guest

WINSCRIPT file

I am new to this winscript and need some help. I want to upload file from my server to SFTP server and then delete the file from local directory.
I created this script which upload the file ftp server without any issue but i am not able to perform the delete step using put- delete command .

option batch abort ------------ THIS SCRIPT WORKS FOR FILE UPLOAD
option confirm off
open sftp://xxx:xx@1xx.247.162.2xx
cd //Locations
put C:\test.txt
close
exit
===================================================
But when i add the delete option with PUT command then it donot works

option batch abort ------------ THIS SCRIPT DONOT WORKS FOR FILE UPLOAD and DELETE
option confirm off
open sftp://xxx:xx@1xx.247.162.2xx
cd //Locations
put -delete C:\test.txt
close
exit
==================================================================================

Can some please review my script and let me know what missing in order to achive delete process once file is uploaded

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
27,227
Location:
Prague, Czechia

Re: WINSCRIPT file

The script looks correct.

Please attach a full log file showing the problem (using the latest version of WinSCP).

To generate log file, use /log=path_to_log_file command-line argument. Submit the log with your post as an attachment. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you can mark the attachment as private.

Reply with quote

Advertisement

You can post new topics in this forum