Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Recover a Visual Studio project that was never saved

I started a new project this morning and, after putting ~3 hours of work into it, I tried to open a file from another project to get some code from it. I got a warning about discarding an unsaved object. After telling it to go ahead, I realized that it was referring to the project I had just been working on and not another file that I had just opened.

Even though I never saved the project, the various files containing my code and dataset had to exist on the hard-drive. Are they still there, perhaps in a temp folder? I'm developing on a box running Server 2008 R2 (don't ask, not my decision :) ).

like image 498
poke Avatar asked Aug 20 '10 17:08

poke


People also ask

How do I recover an unsaved project in Visual Studio?

You can also specify if you want to restore modified files if Visual Studio shuts down unexpectedly. To access this dialog box, go to Tools > Options > Environment > AutoRecover.

How do I recover an unsaved project?

To recover your file, go to File - Open - Open Unsaved Project.

How do I restore a Visual Studio project?

Restore by using MSBuild You can use msbuild -t:restore to restore packages in NuGet 4. x+ and MSBuild 15.1+, which are included with Visual Studio 2017 and higher. This command restores packages in projects that use PackageReference for package references.

Where do deleted files go Visual Studio?

Your VS code deleted files is there in Recycle Bin.


1 Answers

This may help: http://blogs.msdn.com/b/saraford/archive/2008/02/14/did-you-know-where-visual-studio-saves-auto-recovered-files-in-the-case-of-an-unexpected-shutdown-151.aspx

Also check C:\Users{Username}\AppData\Local\Temporary Projects

You could try one of those undelete programs and see if it finds anything.

Tools > Options > Projects and Solutions

and check the item

Save new projects when created

Save frequently. :)

like image 138
Shawn Avatar answered Oct 10 '22 02:10

Shawn