"Changes have been made that cannot be compiled." zero errors and Enable, edit and continue checked in vs2010

I can edit my code in debug mode, but then the error message โ€œEditing that cannot be compiled. Execution cannot continue to install compilation errorsโ€ pops up, but the list of errors is empty, and I checked the edit and continue box. I am using vs2010.

cleaning and restarting did not solve the problem.

+7
debugging c # visual-studio-2010
source share
2 answers

I had this problem with Visual Studio 2008, 2010 and 2013. I wrote a batch file that I store in the solution folder for each of my projects when this problem occurs. Turning around what Vijay said, this clears the bin and obj folders. Sometimes folders will be locked in Visual Studio, and I have to close them, but after I clean them, the problem will disappear ... for a while. I am not sure about the main reason, I believe that binary files and code in memory somehow go out of sync. But this allows you to quickly close, clean, open the solution.

@echo off cls dir bin /s /AD /b > clean.tmp dir obj /s /AD /b >> clean.tmp for /F "tokens=*" %%A in (clean.tmp) do echo rmdir /S /Q "%%A" echo This command will remove ALL BIN and OBJ folders in this tree. echo To run the commands as listed ... pause for /F "tokens=*" %%A in (clean.tmp) do rmdir /S /Q "%%A" del clean.tmp pause 
+1
source share

I am using the Visual Studio 2017 community, updated as of today.

After several hours spent implementing all the solutions posted in this thread, noted by Hao Nguyen in the comments above , the only solution that worked was to delete the workspace and Map&Get again.

To remove the workspace, File โ†’ Source control โ†’ Advanced โ†’ Workspace โ†’ Remove .

0
source share

All Articles