Go Down

Topic: Where'd my code go? (Read 699 times) previous topic - next topic

TFF

Yesterday I wrote a program so that I could get values from an IR distance sensor and use them to control MIDI. When I went to open it today, the file was just blank. Nothing at all inside.

Is there some special way I'm supposed to close the IDE to prevent this, or what? My computer didn't crash mid-edit or anything like that.

retrolefty

#1
Jul 18, 2010, 02:25 am Last Edit: Jul 18, 2010, 02:28 am by retrolefty Reason: 1
Well when you close a IDE window, any code you have entered or changed from the original opening will be saved if you answer yes to the dialog window (which pops up when you close the window) to save, or it won't save any changes made if you answered no to that dialog. Could you have possibly clicked no instead of yes? I have never noticed the IDE 'losing' any of my programs.

You always have the option to explicitly save or save as from the file drop down menu at anytime, without having to close the IDE window you are working in.

Lefty


mowcius

Version 0017 had some saving issues...
Are you using 0018?
I have also never come across the IDE 'losing' programs though.

Mowcius

leppie

The Arduino does not save when you compile/upload. IMO that is silly. I have lost several sketches when my PC crashed and I did not save.

Now I have an OCD about it...

mowcius

Quote
The Arduino does not save when you compile/upload. IMO that is silly. I have lost several sketches when my PC crashed and I did not save.

I would not want it to as I often do some modifications to a sketch, only to then upload it and revert back to the old version. Auto save might be good if you could chose to turn it off. Maybe a backup save rather than saving the actual sketch. Then maybe there could be something like you get on office for document recovery.

Mowcius

Go Up