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

martin

You should start by going to preferences and saving your configuration into an INI file. Then inspect the created INI file to see how WinSCP defines the sessions.
Ryan

Sorry, that last post was made by me. I got logged out somehow.
Guest

Yes, I create the command line in a C# program. If the user wants to launch WinSCP they can, but the folders will be different every time. I can let it go to the default folder every time, but it would be nice to have it open in the right folders.

How would I create the session automatically to have WinSCP open to a different local folder? Looking at the command-line options, I did not see a way to do this.

I am not too familiar with INI files, but I am sure I figure that out.
martin

Re: Command-Line Options

I guess you create the command-line automatically somehow. You can create the session also automatically. The easier is to generate INI file that modifying registry.
Ryan

Command-Line Options

For this syntax to create a session:

winscp.exe [(sftp|ftp|scp)://][user[:password]@]host[:port][/path/[file]] [/privatekey=key_file]

Is there anyway to set the local directory? I want to be able to use the command-line to log into a certain local directory and remote directory. I would create it as a session but the local and remote directories change everytime.

Thanks.