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

StooJ wrote:

It doesn't work though. WinSCP won't take a script file when it's not called manually.

Well it should work. But as I do not know how to your run WinSCP, with what parameters and what script it is hard to tell what's going wrong.
StooJ

A way of allowing WinSCP to run a script, but one that is called from another programme. The only way I can get it to work at the moment is to type it into the command prompt manually.

I have an executable file that lets the user pick a directory, then it generates a WinSCP script to connect to a specific server with a specific username and password and synchronize the chosen directory with one on the server.

It doesn't work though. WinSCP won't take a script file when it's not called manually.

Sorry if I'm not explaining this very well :(
martin

Re: Automating WinSCP

Way around what? What behaviour do you mean?
StooJ

Automating WinSCP

I use WinSCP to connect to my fileserver, and was hoping to let a co-worker upload files to it.

The account I have set up has limited access.

However, I'll need to make something that is fairly idiot-proof.

I tried to create an executable that generates a script and then runs WinSCP with the script.

I found that this doesn't work though, WinSCP has this behaviour disabled as a security measure.

Is there some way around this? A whitelist of scripts or locations? Is there another way to script something with variables (the files will not always be located in the same place on the co-worker's hard drive, so I need to build in a "browse" bit.

Any help, or pointers about where to begin would be greatly appreciated. Many thanks.