2

Due to my system power off my .java file looks like below.

\B5\F3|F03{9....

file size is 50KB so i am hoping it still have data by something went wrong.

In netbeans it shows error

Invalid byte 1 of 1-Byte UTF-8 sequence

Something is messed by, i don't have any backup and there is no History in netbeans.

Can someone guide me with some ideas to get the code from the above file.

Cœur
  • 37,241
  • 25
  • 195
  • 267
user1433804
  • 657
  • 5
  • 17
  • 31
  • Was the source file anywhere near 50KB before this corruption? What OS are you on? – jdphenix Apr 13 '15 at 03:31
  • Not sure, i never saw the file size, (a similar kind of project has 10KB file), i am using ubuntu 14.04 64-bit – user1433804 Apr 13 '15 at 03:43
  • Might see if anything shows in a utility like TestDisk, http://www.cgsecurity.org/wiki/TestDisk:_undelete_file_for_ext2 , note that you want to output to a different partition. or PhotoRec for ext3/ext4 http://www.cgsecurity.org/wiki/PhotoRec – jdphenix Apr 13 '15 at 03:50
  • could you try to open that file using maybe ms word or open office and see what is the result? – kucing_terbang Apr 13 '15 at 04:27
  • Opening in Libre Office shows ���3{9#APIb��J#���J1O#ilv) – user1433804 Apr 13 '15 at 04:57

1 Answers1

0

Well, because it seems the file content's has been overwritten then there is nothing much you can do except try to recover it.

I guess you could try to recover the file using third party data recovery software such as recuva or from wikipedia list

kucing_terbang
  • 4,991
  • 2
  • 22
  • 28