39

I'm writing code in Visual Studio but whenever I want to test the application and press the green arrow for "Start debugging", Visual Studio does not automatically recompile the active solution for me and I have to manually build the solution then debug it.

Visual Studio used to automatically build before debug and I want this back as contantly having to manually build is a serious pain.

Thanks

Kurru
  • 1,744

5 Answers5

50

In the Visual Studio settings under Projects and Solutions->Build and Run change the option On Run, when projects are out of date: from Never Build to Always Build

Edit: Per your comments, open the "Configuration Manager" (in the Debug/Release dropdown) and ensure that the Build checkbox is checked for all of the projects you want to build in each of your configurations.

heavyd
  • 65,321
14
  • Navigate to Debug > Options and Settings in the VS menu or Tools > Options...
  • Go to 'Projects and Solutions' > 'Build and Run' and make sure that the “Only build startup projects and dependencies on Run” box is left unchecked.
Status3543
  • 3,461
Zack
  • 141
0

For me, I was missing the config under Project -> Project Dependencies, which updates the .sln file to ensure correct build order for projects.

aybassiouny
  • 101
  • 2
-1

Tool --> Options --> Project and Solutions --> "On Run, The project is out of date" never build --> change to Always build. I solved me

dsffds
  • 1
-1

Tool --> Options --> Project and Solutions.

  1. Set as Always build / Prompt to Build for "On Run, The project is out of date"
  2. Uncheck the check box for "Only build startup projects and dependencies on Run"