Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

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


Re: WINSCP SFTP transfert issue with a Put command

You are missing some quotes and spaces:

Call Shell( _
"""C:\Program Files (x86)\WinSCP\""  /command " & _
"""open ftpes://... ..."" " & _
"""put C:\Users\sent_FTP\testfile.csv"" " & _
End Sub


WINSCP SFTP transfert issue with a Put command

i wrote the script below in Outlook VBA :

Call Shell( _
"C:\Program Files (x86)\WinSCP\  /command " & _
"""open ftpes:// -timeout=5 -certificate=xxxxxxx -rawsettings ProxyPort=0""" & _
"""put C:\Users\sent_FTP\testfile.csv""" & _
End Sub

when i executes the script, i see in a CMD windows that the remote FTP server is open but the file is not transfered
the command visible in window is : winscp >
if i copy past the command "put C:\Users\sent_FTP\testfile.csv" in CMD windows, that is working very well, the file is transfered

i don't understand why the script doesn't execute the command "put" automatically