Question : FTP - How to FTP from batch, dos or vbscript

Hi,

I need to ftp a file from a unix server to a windows server via windows batch, dos or vbscript?

Windows Server: destserver
Unix Server: sourceserver
Filename on Unix Server: filename.txt
Location of source file on Unix server: /home/hyperion/filename.txt
Location of destination of file on Win Server: D:\CFM\filename.txt

Do I need anyother information?  Possible usernames and passwords?  The script needs to be run from the Windows server too.

Thanks

Answer : FTP - How to FTP from batch, dos or vbscript

In it's simplest, from your destserver:

BAT File Code:

D:\
cd D:\CFM\filename.txt
ftp -s:ftpparams.txt
PAUSE

The ftpparams.txt File Code:

open sourceserver
user {userID}
{password}
cd /home/hyperion/
get filename.txt
bye

Of course edit the userID, password
Random Solutions  
 
programming4us programming4us