Recover deleted data from a saved schematics file

last night I have deleted a lot of data from a my schematics file and have saved the file but now I want to recover all the data that I deleted do you know a way to get it back?

don’t forget that the original footprint is not deleted and all the data is there
this is the pcb file exactly like I want


and the schematic file is empty :frowning:

I can’t give you a step by step, or ever assure you it is possible, however I would go into the project folder and Zip every file there for a backup of where you currently are.

1 Like

If you’re lucky then there is a [projectname].bak file in the project directory or an [projectname].sch-bak

If you were wise you could have just restored a backup (or make one now before you attempt to overwrite files)

If none of the above work then you probably have to redraw your schematic. The links (a.k.a “timestamps” in KiCad V5.1.x) are also gone, so you have to manually match the references (RefDes) in the schematic with the footprints in the PCB.

You also have to either redo the footprint assignment in the schematic, or you can attempt to Pcbnew / File / Export / Footprint Association (.cmp) File and import that in the schematic.

If you’ve fixed the schematic and repaired the links between the schematic and PCB correctly, then you can both Eeschema / Tools / Update PCB from Schematic [F8] and run DRC in Pcbnew without errors.

1 Like

Thank you very much for helping

Here Is what I did :

I found the file .sch-bak
Opened it in note++
Copied all of the 5000 lines
Created a new schematic file
Opened the new schematic file in note++
Pasted all the 5000 lines
Saved the file (as the same name off the old schematic )
Then opened the schematic file from the kicad project and it works

I am so happy

There a number of ways to backup your project. Some folks will suggest a much more elegant method, but personally I zip the project folder periodically or when I’m about to make some significant changes.

That sounds good. That is what I do. But occasionally my zipper gets jammed. :smiley:

LOL

Perhaps rust, should see your urologist :slight_smile:

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.