ftp automation

ScriptFTP

The professional tool to automate FTP, SFTP, FTPS and schedule FTP batch jobs

The forum is now read only. Please, go to the the main ScriptFTP website if you need help.
Need help writing a script? Have any question about ScriptFTP?
How do I call ScriptFTP from a batch file? I want to integrate it within a batch process and I need to pass the set of files it has to upload and I don't want to write a different script file for every possible set of files.

Thanks
Hi,

You can call ScriptFTP.exe or scriptftp_console.exe using your own parameters. The first one is the script file, which is mandatory, but the second, third and so on are optional and for your own use. Then, in the script file, use the command GETPARAM (See http://www.scriptftp.com/reference.php?go=topic153) to retrieve the parameters.

It's also possible to pass information to ScriptFTP using environment variables. You can retrieve them using the GETENV command ( See http://www.scriptftp.com/reference.php?go=topic420)

You can find examples following the above links but if you need further assistance don't hesitate to post here again.
This works fine from a Batch-File, but Ihave a problem wiht following ftp-test.cmd
c:\Programme\ScriptFTP\Scriptftp_console c:\batch\ftp\1.ftp
c:\Programme\ScriptFTP\Scriptftp_console c:\batch\ftp\2.ftp
c:\Programme\ScriptFTP\Scriptftp_console c:\batch\ftp\3.ftp

Mostly the batch-file hangs now at the exit-point of 2.ftp. The cmd.exe freeze and the last output ist
CLOSEHOST
Disconnected

I changed my Batch-file an rewrite all the lines with "call c:\programme\ScriptFTP\" but my simple batch-file freeze, also

BTW: I use your FTP 3.0 DEVEL-Version, because the OK-File-Problem

Kindly regards
Marc
Okay, all my *.ftp-Scripts I synchronized the separate script in one new Script. That is working without problems.

Marc
Sometimes my FTP-Scripts freeze in different positions by calling from a cmd.exe (scriptftp_console.exe)

Mostly it freeze at the point "DISCONNECT", sometimes it freeze at change Directory.

In a scheduled-Task script is this "dangerous""!

Kindly regards
Marc
Hello Marc,

Thanks for the feedback. I've just tested scriptftp_console.exe with hundreds of LOCALCHDIR, CHDIR and CLOSEHOST but it seems to work fine. No hangs at all. Some questions:

Could you send me your script file for testing?
What version of windows are you using?
Does it happens only with the console version?
Are you using the ScriptFTP version available at http://www.scriptftp.com/ScriptFTP_3_0_setup_devel.exe?
Hi again Marc,

Ok. I've just found the bug. Download ScriptFTP_3_0_setup_devel.exe again:
http://www.scriptftp.com/ScriptFTP_3_0_setup_devel.exe

Now, it should not hang anymore. Feel free to post here any concerns.
Hello ScripFTP-Support,

many many thanks for your help. I installed the new DEVEL-Vesion and now it seems to work very, very fine!
Indeed, ScriptFTP it´s a very cool program and it´s very easy to use. Perfect!

Kindly Regards
Marc