FTP check to see if file exists

September 7, 2006 at 09:57:35
Specs: Win xp, 1 g
I am implementing an application using ftp to transfer files from ftp server to local location.
I want to see if a particular file exists before starting the download for all files.
I implement this simply by

"mget xyz*.*"

and then performing the check locally. However the program I am using called "Moveit freely" terminates if the file is not there!!
should I just use normal ftp, cos i tested it and it seems to be working fine even if file is not at ftp server.
or is there any other method to implement check file at ftp?
I read commands like "size file" but these are not present in the Moveit program.


See More: FTP check to see if file exists

Report •

September 7, 2006 at 10:43:38
You could check for a file's presence on the server with the ftp built in to XP. But why not just use that, instead of checking with ftp and mgetting with Moveit?

If at first you don't succeed, you're about average.


Report •

September 9, 2006 at 04:06:29
Are you writing a program? I ask, because the scope of this category is "programming".

If you are curious how to write FTP programs using wininet or winsock, that would be more aligned with this section.

I have written several FTP programs - and you can check the file size, file creation date, and everything else.

Report •

October 1, 2006 at 21:16:43
yes i am indeed writing a program..lol
thats why in this section.
i even wrote down how i was writing the program. ofcourse its calling an ftp application to do the necessary action.

anyway i did not find any good method to check for file presence on ftp so i just used mget with normal ftp.

Report •

Related Solutions

Ask Question