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.

Options
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)

Options

Topic review

Nizar

Re: Upload file from perticular local Directory

Thanks a lot it worked now. Appreciate your help.
martin

Re: Upload file from perticular local Directory

You need to wrap any path with spaces to double quotes (it does not harm to wrap any path to double quotes).

I.e. lcd "D:\MY FTP\Upload"
Nizar

Re: Upload file from perticular local Directory

Thanks Martin. I use "lcd D:\FTP\Upload" and it works fine.

But when I change it to the folder name with space it provides error message Too many parameters for command 'lcd'. For example, it provides error message for "lcd D:\MY FTP\Upload". Is there anyway, I can include folder/directory with space?

For you information, I am using WinSCP Portable application (v5.5.4.0).
martin

Re: Upload file from perticular local Directory

Just use a full path to the file:

put D:\FTP\Upload\test.txt

Or change local working directory to D:\FTP\Upload. Either before starting WinSCP or from WinSCP script using lcd D:\FTP\Upload.
Nizar

Upload file from perticular local Directory

Hi Team,

I am new to WinSCP. I use following script and it works fine to upload test.txt file exists in "winscp554" directory. I want to upload file from local directory "D:\FTP\Upload" instead of "C:\winscp554". Would you please guide me in proper direction?

I am using WinSCP product version 5.5.4.0. Please let me know if you require more info. Thanks in Advance.

C:\winscp554>WinSCP.com /script=FTP_Upload.txt

--------------- FTP_Upload.txt -----------
option batch abort
option confirm off
open sftp://user:password@example.com/
put test.txt
exit
------------------------------------------