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

Re: waitonreturn doesn't work

The very purpose of the Windows start command is to run something in a separate window without blocking the original process. Remove it. I do not know, what language/environment your code is in (some kind of VB?), but removing whole C:\Windows\System32\cmd.exe /c start should do.
This is not WinSCP question.
nedu_83@yahoo.com

waitonreturn doesn't work

Hi, I'm trying to download files from remote server and process it. But the coding execute the next step before the /command completed.

my coding;
fetch.Run "C:\Windows\System32\cmd.exe /c start C:\""Program Files (x86)""\WinSCP\WinSCP.com /ini=nul /command " + _
"""open ftp://xxx:xxx@xxxx"" " + _
"""cd \xx\xxx\xxxx\1"" ""get logsc:\tmp\file1"" " + _
"""cd \xx\xxx\xxxx\2"" ""get logsc:\tmp\file2"" " + _
"""cd \xx\xxx\xxxx\3"" ""get logsc:\tmp\file3"" " + _
"""close"" ""exit"" ", windowStyle, waitOnReturn