The Visual Studio Edit and Continue feature stopped on Visual Studio 2010, and I don\'t know what has caused the problem.
I am working on a Windows application progr
In the Solution Explorer view, right-click on each reference of References, choose Properties. In the Properties view, sign False to the field of Embed Interop Types. This works for me.
Removing the * from the assembly versions of my referenced projects solved the issue for me.
From Github:
"I reproduced this issue on a mix of VB and C# projects with [assembly: AssemblyVersion(1.2.3.*")]. Once a VB project references a C# project with this setting things start collapsing. It looks like it has the same problem the other way around." -rhuijben
https://github.com/dotnet/roslyn/issues/28224
(At risk of being flagged, seems we have been suffering from VS Edit and Continue issues for over a decade. It's shocking to me that the Microsoft Visual Studio team hasn't cared enough to help developers by providing more verbose info when this occurs)
Reading the above, my UI project has Shell32 with "Embed Interop Types" == true. I changed it to false, and "edit and continue" started working.
No dynamic/Portable Class Libraries/Nuget packages or dependancy problems. No errors or warning highlighted by Visual Studio.
After hours spent trying all the solutions posted in this and other threads and webpages, the only solution that worked for me was to check-in, remove the Workspace and Map&Get
again.
To remove the Workspace, Source control
→ Advanced
→ Workspace
→ Remove
.
I'm using Visual Studio 2017 Community up to date and after a relatively fresh install on a new machine (one week and few work hours).
Methods I've tested with no success prior to the solution above
<_ResolveReferenceDependencies>
to true
as explained hereAfter this, I made a check-in and downloaded the Solution on another machine running the same version of Visual Studio (2017 Community). As I didn't get the Edit&Continue issue there, I went for the Workspace removal.
In my situation, someone added a Reference to the Project's output into the Reference list: in Solution Explorer look under [ProjectName]\References for [ProjectName*] and remove it.
If the project is relying on code from a copy of itself, you can't 'Edit and Continue'. In the warning list you may or may not (more likely to in a larger project) have 'conflicts with imported type' messages if this is the cause of the problem.
In VS2013 I had to enable "Use Managed Compatibility Mode" in the debugging options. I think it is because I have a .Net 4 project referencing a .Net 2 assembly.
For another project in the same solution I had to uncheck "Define TRACE constant" in the project properties.