Re: Check for a file in an ftp directory
- From: Michael Bednarek <ROT13-zo@xxxxxxxxxxxxx>
- Date: Sun, 12 Jun 2005 15:46:36 +1000
On Sat, 11 Jun 2005 13:18:29 -0400, "Mostro" <mostro@xxxxxxxxxx> wrote
in microsoft.public.scripting.wsh:
>I would like to run a script (WSH/VB) from my desktop to check on files that
>have been uploaded to an FTP site. I don't want to download the file or
>upload a file just check if the file name and/or the extension exists. Can
>someone point me in the right direction.
Any reason why this has to be in VBS? The command line interpreter I use
(4NT) incorporates FTP in a rather transparent manner. In your case, the
command would look like:
IF EXIST "ftp://server/dir/fu.bar" ECHO fu.bar exists.
This feature is documented at <http://jpsoft.com/help/ftpservers.htm>.
4NT is a commercial product.
FYI: I use something similar every day where a scheduled batch file
checks whether the required number of files are present on a FTP server;
it even checks their content with 4NT's equivalent of FIND.EXE (FFIND)
for correct information before downloading, which of course is just a
simple COPY command:
COPY "ftp://server/dir/fu.bar" d:\dir\
--
Michael Bednarek http://mbednarek.com/ "POST NO BILLS"
.
- References:
- Check for a file in an ftp directory
- From: Mostro
- Check for a file in an ftp directory
- Prev by Date: Re: Check for a file in an ftp directory
- Next by Date: Startup script. Machine v User
- Previous by thread: Re: Check for a file in an ftp directory
- Next by thread: Re: Setting folder permissions via script
- Index(es):
Relevant Pages
|