Document wiped despite AutoRecovery on

I had a document which was open in LibreOffice. I’m not sure what happened exactly, I was trying to hit “Shift+1” for an exclamation mark, but I hit something else (Ctrl+W maybe?) or maybe the program just crashed coincidentally.

When I tried to open my file again, it was completely gone and unrecoverable. Opening it with Notepad or a hex editor revealed that the entire file’s contents had been converted to whitespace.

AutoRecovery was on, but it didn’t help, and there were no files in the backup folder.

Can anybody tell me why this happened and how to prevent it in the future?
Edit: I should clarify that I’m not asking for other ways to back up my data (I had older backups from outside measures), I’m really just trying to find out if anybody might know why AutoRecovery failed.

Maybe you hit Ctrl+Q?

Have a look to see if there is still a temp file, this question should help, retrieving spreadsheet document after computer crash

Preventing data disaster

No temp files, I tried opening all the *.tmp files in %temp%.

Why “%temp%”? Both links ny @Hrbrgr and @EarnestAl point to discussions that mention

Sorry for not clarifying, that’s where the LibreOffice temporary files are stored, in the system temporary files directory. That’s what it puts in by default when LibreOffice is installed.

No, the default location for autorecovery is under user profile.

So likely the mention of “temporary files” in the linked answer was misleading.

The other one was correct, though.

The path value for autorecovery is the “backup” directory, which I already mentioned checking in my first post.

Edit: Okay well now I don’t know what you mean at all. The link you provided says that only the “Always create backup copy” data goes into “backup”. And neither that link or the previous link about preventing data disaster mentions any bespoke path for AutoRecovery data itself.

A temp file is created where it says in Tools > Options > LibreOffice > Paths > Temporary Files. If LibreOffice is closed properly, the temp file is destroyed but if LibreOffice crashes it can be left behind and sometimes contents can be recovered.

If you don’t see any folders in the style lu....tmp then probably your original guess that it was properly closed by Ctrl+W (I recall that in Windows XP, Ctrl+W closed the window without save dialogue) is correct and the temp file has been destroyed. By default there is a warning dialogue about save before closing.


Thank you very much. That does provide me with a scenario: Though I’m still not sure how I blazed past the save dialogue confirmation (I must have really fat-fingered it), if that’s what happened, then it makes sense that there was no AutoRecovery data, since as you said it didn’t actually crash.