DOS FTP-batch
|
Original Message
|
Name: Wever
Date: June 25, 2002 at 07:20:49 Pacific
Subject: DOS FTP-batch
|
Comment: Hi All, I wanna make a batch that automatically logson to a server, gets some files and quits. I wanna start it by doubleclicking an icon at my desktop.Is that possible ?
Report Offensive Message For Removal
|
|
Response Number 1
|
Name: Secret_Doom
Date: June 25, 2002 at 10:03:01 Pacific
Subject: DOS FTP-batch
|
Reply: (edit)Yep, that's possible. Let's suppose the FTP commands you would type for doing that are: open ftp.server.com USER username password get file1.dat get file2.dat Then, the batch file would be: @echo off echo open ftp.server.com> SCRIPT.DAT echo USER username>> SCRIPT.DAT echo password>> SCRIPT.DAT echo get file1.dat>> SCRIPT.DAT echo get file2.dat>> SCRIPT.DAT FTP -n -s:SCRIPT.DAT del SCRIPT.DAT -- Leonardo Pignataro - Secret_Doom -- secret_doom@hotmail.com www.batch.hpg.com.br
Report Offensive Follow Up For Removal
|
|
Response Number 2
|
Name: Wever
Date: June 26, 2002 at 01:50:44 Pacific
Subject: DOS FTP-batch
|
Reply: (edit)Tnxieee, nice to see u again... But i don't get the last line: del SCRIPT.DAT Why would i do that ? The batch is supposed to work with 1 file i have to get from an ftp-site. Each week the same file. Can i put a QUIT at the end ?
Report Offensive Follow Up For Removal
|
|
Response Number 3
|
Name: Secret_Doom
Date: June 26, 2002 at 15:00:21 Pacific
Subject: DOS FTP-batch
|
Reply: (edit)Hi, Wever. The way the batch is, it won't need any other files to run, nor will leave any files behind. But you could also leave the script file saved and use it ny the batch file. === SCRIPT.DAT === open ftp.server.com USER username password get file1.dat get file2.dat === BATCH FILE === FTP -n -s:SCRIPT.DAT If you use that method, the process will obviously fail if SCRIPT.DAT isn't there. -- Leonardo Pignataro - Secret_Doom -- secret_doom@hotmail.com www.batch.hpg.com.br
Report Offensive Follow Up For Removal
|
|
Response Number 4
|
Name: David Steven
Date: July 3, 2002 at 11:38:28 Pacific
Subject: DOS FTP-batch
|
Reply: (edit)Another reason to have the bat file create the ftp script every time: Your ftp script is probably going to have your password in it. So having the batch file create the script keeps the password only slightly more hidden. You could also use one of those BAT file compilers and compile the bat making it a little more hard to find. Mind you, its not that hard for anyone that know's what they're doing. But you just make it a little more inconvient.
Report Offensive Follow Up For Removal
|
Use following form to reply to current message: