Comparison Of FTP File Time With Local File Time Fails
Comparison Of FTP File Time With Local File Time Fails
I have a VB application that needs to download a file from an FTP server
only if it is newer than the one on the local machine. I am using the
WinInet API call 'FtpFindFirstFile' to obtain the last modified time of the
file on the FTP server. I then use the Win32 API function
'FileTimeToLocalFileTime' in the application to convert this time to the
local time zone. Then I make a call 'FileTimeToSystemTime ' to get the
result in the system time format. I then compare the result with the last
modified time of the same file on the local machine.
It has been observed that even if the file on the local machine is uploaded
on to the FTP site and the above process is used, the file times do not
match.
I encountered the articles listed below, but cannot figure out where I am
wrong nor what I should do.
Please help!
Peter Lever.
http://www.*-*-*.com/ ;EN-US;q167296
http://www.*-*-*.com/ ;EN-US;q190315
http://www.*-*-*.com/ ;EN-US;Q158588