|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
recover or recuperate deleted file
hi all,
i'm totally new at this so.....be gentle...lol in some programs it's possible to recover or recuperate a deleted or missing file.... any idea? help would be very much appreciated |
|
#2
|
|||
|
|||
|
Good old DOS times ...
With most modern OSs this is close to impossible because they can overwrite the deleted file's data immediately. If you deleted a file by accident, in the same second you have to make this decision: - Is it worth pressing the power switch immediately? Then you usually have a good chance to recover files because the write cache might not have been flushed. But you might destroy other data with this, so use on your own risk. Then boot from a CD or Floppy and start a recovery program. Still there is no guarantee that it can do anything for you. And the probability of a successful recovery depends on many other factors too. If the OS does any further write actions to this partition though, like when shutting down, it could be too late. You asked this in the Delphi Forums, so I guess you want to know how to write such a program? You need to download the specifications for your file system. In case of eg. NTFS this is not publicly available. Then you can write a program that reads the partition sector by sector and it will be your program that has to analyze the structure according to the specifications, search for the lost data and try to rebuild the file from the raw sectors. In windows you'll have to search the WinAPI for the functions to read raw sectors. You can then boot into the recovery console and run the program from there. Another way would be a DOS program using BIOS int13h to read raw sectors. hth, ...M
__________________
-- Manuel Hirsch - Linux, FreeBSD, programming, administration articles, tutorials and more. |
|
#3
|
||||
|
||||
|
Are you talking about just recovering from the recycle bin, or actually rebuilding the file by going to the FAT (or NTFS) tables. If you're talking about the latter, then you probably want to visit Torry's pages. Notice that there's a component to read file sectors (Absolute Read/Write Hard Disk) there, as well as an undelete program (Back2Life). Perhaps you can convince the Back2Life author to let you see the source
.
__________________
Up the Irons What Would Jimi Do? Smash amps. Burn guitar. Take the groupies home. "Death Before Dishonour, my Friends!!" - Bruce D ickinson, Iron Maiden Aug 20, 2005 @ OzzFest Down with Sharon Osbourne Puzzle of the Month solved by Keath and KevinADC, superior perl programmers of the month Looking for a perl job with kick-*** programmers in a well-known NASDAQ listed tech company with branches in the US and Europe? We're hiring. PM me for details. Requirements |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > Delphi Programming > recover or recuperate deleted file |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|