I know I've dealt with this issue before, but the settings to override this always seem to be changing.
I have a C# project in Visual Studio 2008. While I'm debugging, VS won't let me edit my code. I don't want to Edit and Continue - I just want to make changes for my next build. Edit and Continue is disabled. When I try to edit a file while debugging my project, I get a little message that the files are now Read-Only.
Anyone dealt with this recently in VS2K8?
Tools + Options, Debugging + Edit and Continue. Turn off the Enable checkbox. You can now edit the source code. You will get a warning when you continue to debug after you've made a change.
I am not sure why Edit and Continue won't work for you. If you are debugging and attached to the process you are debugging in, your pages should be locked or the debugger can't show you what is actively running.
Here is a reference to Edit and Continue.
http://whyiamright.wordpress.com/2007/12/20/aspnet-edit-and-continue-in-visual-studio-2005/
If you are programming for the next build, it doesn't make sense to me to be trying to debug your current build.
The last time I had this problem I fixed it by changing the following settings:
Project properties -> Compile -> Advanced Compile Options -> Set "Generate debug info" to Full and uncheck "Enable optimizations".
Worked for me. Don't know about you, though.
I just tried this in VS2k8. All I had to do was enable Edit and Continue in Tools > Options > Debugging menu.
You won't be able to use E&C when you have projects set to release mode
Thanks everyone for your input, even the comments that directly contradict each other. I had tried enabling and disabling Edit-and-Continue a handful of times to no effect. However, I just restarted VS and now my enabling/disabling E&C is affecting my ability to edit during debugging just the way I would have expected. I guess it was just a bug in VS...
Thanks again.
In VS 2010, go to Debug->Options->tick Enable Address Level Debugging :) reverse for reverse operation :)