4

for C# there's this option in VS for hot reloading, to automatically rebuild and restart the application. This is usually necessary when the changes couldn't be applied while the application was running. In practice, this happens a lot when you have a syntax error and press save. Unfortunately, I checked the option "always rebuild when changes can't be applied while running the application" (I don't remember the exact name of this option). So now, each time when I have a syntax error and accidentally save the file, it exits the application I'm debugging, while I could have easily fixed the syntax error and saved again, without restarting.

Is there a way to restore this setting such that the dialog pops up again, asking me whether I want to continue editing or restart the application? I believe this dialog is called "rude edit". I tried to find the option in the settings of Visual Studio, but could not find it. A work-around is to disable hot reloading on file save, and manually triggering the hot reload after I save a file, but I'd rather have the old behavior.

2 Answers2

5

Apparently, this setting persists during the lifetime of a single VS session, and is reset if you restart it. I should have read it better before clicking the checkbox.

Hot Reload dialog

For completeness, the caption of the checkbox is "Always rebuild when updates cannot be automatically applied. This checkbox will be reset when the solution is closed."

-2

enter image description here

Change "release" and select "Debug".

Jeremy Caney
  • 7,102
  • 69
  • 48
  • 77