It is currently Sat May 18, 2013 9:21 pm

All times are UTC + 1 hour




Post new topic Reply to topic  [ 9 posts ] 
Author Message
 Post subject: Problem with PB
PostPosted: Sun Mar 04, 2012 9:08 pm 
Offline
Enthusiast
Enthusiast

Joined: Thu Feb 03, 2011 7:44 pm
Posts: 164
Hey

I left my computer on for about 20 mins and when I came back i think someone had slept it or it went to sleep anyway when i resumed it i noticed this weird graphical thing happenening with all programs so I closed all programs including PB then restarted my computer. The graphical error went away however something wrong happened with PureBasic : When I opened it up all my preferences were gone (Default PureBasic startup + Splash screen) and the file i'd been working on disappeared. So when I tried to open the file i was working on it came up in File Viewer with just a list of numbers:

00000000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00000010 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................

I really need that file back as it contained a lot of code i had been working on . Is there anything i can do to retrieve it ?

Nubcake


Top
 Profile  
 
 Post subject: Re: Problem with PB
PostPosted: Mon Mar 05, 2012 1:14 am 
Offline
Addict
Addict
User avatar

Joined: Wed Feb 17, 2010 12:00 am
Posts: 972
Location: Anderson Island, WA
what you describe is a classic sign of shutting the system off rather than doing a full system shutdown...

If the file is filled with nulls, you're not going to get it back; unless you boot off a cd and look for traces of the old file.

If you've powered your machine on and used any programs, chances of recovering go download dramatically.


Top
 Profile  
 
 Post subject: Re: Problem with PB
PostPosted: Mon Mar 05, 2012 6:11 pm 
Offline
Enthusiast
Enthusiast

Joined: Thu Feb 03, 2011 7:44 pm
Posts: 164
so there's no chance of recovery?


Top
 Profile  
 
 Post subject: Re: Problem with PB
PostPosted: Mon Mar 05, 2012 6:34 pm 
Offline
Addict
Addict

Joined: Fri Oct 23, 2009 2:33 am
Posts: 2852
Location: Wales, UK
Do you keep a backup? If not, now is the time to start. Concerning the issue on your PC, you need to try to find the cause since it is unlikely to be a one-off.

_________________
IdeasVacuum
If it sounds simple, you have not grasped the complexity.


Top
 Profile  
 
 Post subject: Re: Problem with PB
PostPosted: Mon Mar 05, 2012 7:37 pm 
Offline
Enthusiast
Enthusiast

Joined: Fri Feb 24, 2006 9:40 am
Posts: 290
There are plenty of file recovery tools. You could ask google for things like "undelete" or "recover files windows" and with a bit of luck, some time and the right tool, you can recover at least a previous version of your source.

For example the "tuneup utitilities" have a 30day trial and contain undelete tools. Maybe you want to try that as most dedicated recovery tool trials don't allow you to save the data during trial, but tuneup might.

If you are very serious about getting the file back, you would not ever start the installation again (risk of overwriting data you want to recover) and only work on a 1:1 image copy you create right after it happened. If it was a faulty suspend mode (incompatible/faulty drivers or hardware), you might find your source in the memory dump windows created on the hard disk. Make a copy, open it with a hex editor and search for a unique string in your source.

You might only get an older version back though, or 90% of your file.

ps: obviously if you install the recovery tools on the same partition/system where you want to undelete data from, you might overwrite the data with that installation ;)


Top
 Profile  
 
 Post subject: Re: Problem with PB
PostPosted: Mon Mar 05, 2012 9:08 pm 
Offline
Enthusiast
Enthusiast

Joined: Thu Feb 03, 2011 7:44 pm
Posts: 164
the only thing close enough to the file was a compiled exe that i still have but im guessing decompiling is out of the question right ?


Top
 Profile  
 
 Post subject: Re: Problem with PB
PostPosted: Tue Mar 06, 2012 2:14 am 
Offline
Addict
Addict
User avatar

Joined: Tue Dec 23, 2003 3:54 am
Posts: 932
Location: New York
A similar thing happened to me when I was editing code under Linux, my laptop battery died, and later I rebooted to Windows XP. My code had become corrupt -- filled with nulls and garbage. I assume it had something to do with the OS, or the filesystem, from not saving and closing the file buffers. Luckily I had backups :?

I have had decent luck with the (free?) recovery program Recuva, although that was on flash/SD drives, and it is always best if you try to recover immediately running as little software as possible (so you don't overwrite that area of the hard drive unintentionally).


Top
 Profile  
 
 Post subject: Re: Problem with PB
PostPosted: Tue Mar 06, 2012 7:27 am 
Offline
Enthusiast
Enthusiast

Joined: Fri Feb 24, 2006 9:40 am
Posts: 290
Nubcake wrote:
the only thing close enough to the file was a compiled exe that i still have but im guessing decompiling is out of the question right ?


You can decompile it to assembler or C/C++, but you wont even be able to change and compile the resulting C/C++ code anymore.

I dont know how much trouble it would be worth to you or how many files we talk about. An easy way to check if there even is a point in trying to recover data, would be to use a linux life CD/DVD like knoppix and do a grep for a unique string on the raw filesystem. That would show you if (fragments) of your source still exist somewhere. A diskeditor and some hours of re-assembling parts from the raw disk, might be worth it for you - or not. Think carefully about the string you search for - the search usually takes hours - thats why professionals copy the images to a super-fast device before doing stuff like that (SSD-Raids).

A good IDE creates backup files or even a backup history for cases like this (i think japbe does it), but lack of backup was of cause your major mistake.


Top
 Profile  
 
 Post subject: Re: Problem with PB
PostPosted: Tue Mar 06, 2012 9:06 pm 
Offline
Addict
Addict
User avatar

Joined: Tue Dec 23, 2003 3:54 am
Posts: 932
Location: New York
Doesn't PB create a temporary copy of your source when you compile/run? Or is that just for new, unsaved source code...

Maybe, if you haven't run PureBasic since then, there is still a good copy in you compiler folder or elsewhere?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 9 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: Exabot [Bot] and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  

 


Powered by phpBB © 2008 phpBB Group
subSilver+ theme by Canver Software, sponsor Sanal Modifiye