Consultor Eletrônico



Kbase P3450: How can I tell if the transfer of a file via FTP is complete
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   06/05/2003
Status: Verified

GOAL:

How can I tell if the transfer of a file via FTP is complete?

FIX:

For each file that is transferred via FTP, transfer a second file that is simply a 'flag' to indicate that the corresponding 'real' file has been transferred.  In the application simply check for the existence of the 'flag' file before attempting to open the 'real' file.

To check for the existence of the 'flag' file use code similar to the following:


FILE-INFO:FILE-NAME = 'NameOfFlagFileGoesHere'.
IF FILE-INFO:FULL-PATHNAME NE ? THEN
... Flag File Exists So Open Real File And Process The Contents ...