Scrivener Error After Crash

Today, I was just finishing up a scene to my novel when my computer decided to die (just before I clicked ‘save’). I tried opening up the backup files but I was unable to find a version that was saved before the crash (I only had 5 backups available for that project; if there are more than 5 do the old ones just get deleted?). My computer has done this once before and Scrivener actually did save the writing and it was there when I reopened the document, but that didn’t happen this time. I don’t have any faith that I’ll recover my lost writing, but I still have an issue. Whenever I open up my file (or the backup files), Scrivener has a pop-up that says “Errors reading project. Error: Error reading template info: Line:1 Column:2 Error:1.”

Is there any way I can fix this error so that a) I can get the scene back that I lost and/or b) stop the pop-up from opening every time I open my file?

Thanks for any advice!


Scrivener’s default settings are to save the five most recent automatic backups per project, so yes, after five, the oldest will be replaced by the new backup. You can change these settings in the Backup tab of Tools > Options, so definitely give that a look; it won’t help in the current situation, sadly, but it will make you better prepared for any future unfortunate events.

In this case, it sounds like either your new text was never saved–Scrivener autosaves every two seconds of inactivity, so this usually isn’t a problem, but if you adjusted that to a higher number and or went on a typing streak without pause, it’s possible–or, more likely if I understand correctly, the open text file was corrupted when the computer crashed. It wouldn’t matter that the text was saved to the file then, since the whole file was damaged. You could try digging into the project’s .scriv folder (into Files\Docs) and opening the problem file in a plain-text editor like Notepad; there may be some text still recoverable in an otherwise unreadable file. It’s pretty unlikely but may be worth a try. The files are named just with a number, but you may be able to guess at it from the modified date or the file size. To be safe, I’d right-click the project folder and use “Send to \ Compressed (zipped) folder” to create another backup first.

Another possibility is that there’s some text from the document still saved in the search.indexes file in the oldest of the backups you do have. Again, this is a long shot, especially since your oldest backup may not be the first backup following the crash, but if there was text from the document saved in the search index and if that didn’t get re-indexed post-crash (thus updating it to not have the non-existent text), it may be salvageable. You can check in the Files folder inside your oldest backup for the project and open the “search.indexes” file in a plain-text editor. Search for the document title, then see if there’s any of the document text associated with it in the file. It will be unformatted if it’s there, but you can copy it out and clean it up.

The error message you’re getting is much simpler to solve; the templateinfo.xml file it indicates is only used to auto-populate the “category” and “description” fields when using Save As Template, so it’s nothing serious. Deleting the file with the project closed will prevent the error message recurring and will not affect anything else in the project:

  1. Close the project.
  2. Open Windows Explorer and locate the project’s .scriv folder on your hard drive.
  3. Navigate into the “Settings” sub-folder.
  4. Delete the file called “templateinfo.xml”.

Once you’ve done this, you should be able to reopen the project without seeing the error, and the file will just be recreated if you ever use Save As Template, saving the new info you enter then.

Thanks for your help! Unfortunately, I couldn’t find the lost text, so I just had to re-write the scene. I was able to fix the error using your suggestion. At least now I have a better understanding of how Scrivener backs up my documents, and where I can likely find text if I lose it in the future. Thanks!

I’m sorry you weren’t able to retrieve the lost work. The rewrite is always better though, right? :slight_smile: And it’s definitely worth familiarising yourself with the backup options in Scrivener to make the best use of them.