Click here to Skip to main content
15,881,882 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
Hello everyone, new guy here. Does anybody know how to recover files that were deleted on publishing a web page on visual studio? I selected the "Delete existing files" option in the Web Publish prompt, and I accidentally selected the folder of another VS project as the publishing folder, so it was deleted. How can I recover this folder? Thanks in advance and sorry for my bad English.

What I have tried:

Looking up in recycle bin, looking up in temp folder.
Posted
Updated 3-Jan-17 11:34am
Comments
[no name] 3-Jan-17 12:35pm    
You just learned the value of source control and making backups.
jgakenhe 3-Jan-17 13:04pm    
It's gone forever. You'll need to redeploy the application that was overwritten, if it is production.

My suggestion to you is create a deployment process; so this never happens again.

I typically publish to file system (aka my computer) Each VS Project has its own profile (.publish) that saves that information for me. Then I use RoboCopy to copy to the destination, either test or prod. And most importantly, I use RoboCopy to create a backup. This way, if the deployment is screwed up, then I have a backup I can put back out there in seconds. There are new ways to do this, but RoboCopy has served me well.

YouTube has tutorials and examples
Afzaal Ahmad Zeeshan 3-Jan-17 13:32pm    
My virtual 5 to you. :-)
Maciej Los 3-Jan-17 15:04pm    
And 5 from me!
jgakenhe 3-Jan-17 15:43pm    
Thanks, I just went ahead and posted it so others don't read this unnecessarily.

It's gone forever. You'll need to redeploy the application that was overwritten, if it is production.

My suggestion to you is create a deployment process; so this never happens again.

I typically publish to file system (aka my computer) Each VS Project has its own profile (.publish) that saves that information for me. Then I use RoboCopy to copy to the destination, either test or prod. And most importantly, I use RoboCopy to create a backup. This way, if the deployment is screwed up, then I have a backup I can put back out there in seconds. There are new ways to do this, but RoboCopy has served me well.

YouTube has tutorials and examples.
 
Share this answer
 
Comments
Maciej Los 3-Jan-17 17:21pm    
Real 5!
One of the way to recover files, is to use recovery tools. For example, below is given a list of free for non-commercial use tools:
UnDelete[^],
Active@ UNDELETE Freeware[^]
Recuva[^]
RedoBackup And Recovery[^]
etc.

Note: there's no 100% guaranty that you'll be able to restore all files and entire content. So, the method provided by jgakenhe[^] is probably the best way to protect yourself for unwanted or accidental deletion, malware or virus infection of files.

Good luck!
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900