WinBatch® Technical Support Forum

All Things WinBatch => WinBatch => Topic started by: MW4 on August 07, 2014, 01:04:21 PM

Title: Is there a watch folders for FTP?
Post by: MW4 on August 07, 2014, 01:04:21 PM
I use the "Watch for file then do something" and it works awesomely.

Currently I have a need to watch an FTP folder for additions of specifically named files with a date back-end so I need a wildcard type view such as ABCD_10-10-2014.txt....  ABCD_*.txt

Is this possible?
Title: Re: Is there a watch folders for FTP?
Post by: Deana on August 07, 2014, 01:29:49 PM
Yes possible, but not using the same method. I would use FTP operation in a While loop with a specified TimeDelay.

This FtpListFileNames UDF can help you get a list of files on the FTP server, you can then use StrIndexWild to see if one of the file names matches your filename wildcard.
http://techsupt.winbatch.com/webcgi/webbatch.exe?techsupt/nftechsupt.web+WIL~Extenders/WinInet+FtpListFileNames~UDF.txt
Title: Re: Is there a watch folders for FTP?
Post by: DAG_P6 on September 03, 2014, 10:22:24 PM
Beware. FTP can be very fussy unless you control every bit of the connection between the two hosts. We've been using FTP, off and on, for years, in similar fashion. So long as we were dealing exclusively with hosts that lived in data centers, we had very few issues. However, in the last couple of years, we have begun using FTP to transfer files back and forth between computers located in remote offices and our data centers. Most of the time, it's still OK, but we have periods when it gets really difficult to get files to and from some of our remote hosts. The problems tend to be intermittent, and eventually settle down, but it's enough of a problem that we are replacing some parts of it with a Web service that will behave much more like a credit card terminal.
Title: Re: Is there a watch folders for FTP?
Post by: morenos1 on September 04, 2014, 06:42:39 AM
You can try to mount the FTP location as a local windows drive and watch it that way ....

http://www.expandrive.com/expandrive