What is the difference between Build Solution, Rebuild Solution, and Clean Solution in Visual Studio?
When is the appropriate time to use each one of these?
For a multi-project solution, "rebuild solution" does a "clean" followed by a "build" for each project (possibly in parallel). Whereas a "clean solution" followed by a "build solution" first cleans all projects (possibly in parallel) and then builds all projects (possibly in parallel).
Clean Solution : deletes all compiled files (all dll's and exe's ). Build Solution : compiles code files (dll and exe) that have changed.
The main difference between build and rebuild in Visual Studio is that the build helps to complete the code files that are changed, while rebuild deletes all previously compiled files and compiles the solution from scratch, ignoring anything done before.
On the menu bar, choose Build, and then choose either Build ProjectName or Rebuild ProjectName. Choose Build ProjectName to build only those project components that have changed since the most recent build. Choose Rebuild ProjectName to "clean" the project and then build the project files and all project components.
(The links are to the devenv.exe command line switches, but they do the same as the menu items.)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With