[EpiData-list] How to: Recapture a corrupted file

epidata-list at lists.umanitoba.ca epidata-list at lists.umanitoba.ca
Wed Oct 12 09:04:38 CDT 2005

In some versions of some computers open files can get "messed" up if power is suddenly lost. 

Over the years we have strengthened EpiData Entry with several alternative mechanisms to try to avoid problems in this situation (e.g. only one record at a time is in memory. The rest is on the  harddisk or floppy.). But despite this the error have been reported at rare instances. Also over the years I have seen files from this situation which was a combination of a rec datafile, a word document and a presentation or drawing. In other words this is part of a operating system problem. 

How to resolve ?

If a corrupted file message is given you can do the following: 

Manual repair of corrupt files: 

1 Make a second copy of your REC and CHK files and do the following 
      (MAKE SURE IT IS A COPY !!!):

2. Verify that YOU HAVE THE ORIGINAL CORRUPTED file in a separate place.

3 Open the extra copy of the REC file in any ascii editor (e.g. notepad.exe).
4  Make sure you are using a fixed font. 
5  Look for records with strange or odd formatted records and delete the complete record
    (Make a note of which one such that you can re-enter it later in EpiData)
6   Delete the parts with a strange format.
7   Pay particular notion to length of lines. All records should show same pattern.
8   Save the file and try to open in EpiData. 

If you think the above is hopeless - then try to regain other documents or files that were also open at the time, e.g a spreadsheet, a text document or a database from another programme than EpiData.

The above is a modifed version of a user supplied explanation earlier.


Jens Lauritsen
EpiData Association

More information about the EpiData-list mailing list