MGET for specific file.

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Message
Author
Squashman
Expert
Posts: 4465
Joined: 23 Dec 2011 13:59

Re: MGET for specific file.

#16 Post by Squashman » 27 Jun 2014 01:46

saw that coming a 1,000 miles away. Literally. I was that far away from home.

foxidrive
Expert
Posts: 6031
Joined: 10 Feb 2012 02:20

Re: MGET for specific file.

#17 Post by foxidrive » 27 Jun 2014 04:18

I hope you are on holiday Squashman! :)

slstrozier
Posts: 8
Joined: 24 Jun 2014 07:46

Re: MGET for specific file.

#18 Post by slstrozier » 27 Jun 2014 05:28

foxidrive wrote:That shows me that you are expecting a batch file command to work in an FTP script,
and you aren't using the batch file that was provided.

The batch file is meant to be clicked on to launch it. Or you type the batch filename to launch it.
It creates a new FTP script every time it runs, and launches FTP.EXE itself.

You can add a line at the bottom with: del ftp.script
so that it deletes the temporary FTP script when it is done.

Just a tip here - don't call the batch file FTP.bat


Thanks Foxidrive for your help. Yes, I am using a batch file that is calling an ftp script. And the ftp script is not literally named 'ftpfile.ftp'. I made generic names for this posting. The bat file is called by a task that has been set up in windows task scheduler. Is this setup somehow a reason that would prevent me from accomplishing the task of getting the specific set of files.

For a little more background here is the current ftp file:
open ftp.server.com
user user1 P@55Word1
lcd "C:\DownloadFiles"
prompt
mget "Area * BIG.pdf"
close
quit
It downloads all files that match "Area * BIG.pdf", which is currently close to 400 files @ about 200kb a piece. At times the download times out and does't complete the transfer of files. I believe this is because there are too many files or either too much data being transfered and Im thinking this could be solved if I could get half the files first, then close and re-open the connection and get the remaining files. Is something like this even possible?

Again, Thank you for your help

Post Reply