简体   繁体   中英

How can I build all projects in a solution by clicking Start?

I have a solution with my main windows application project and several class libraries. When I run the main project I would like to also automatically build the libraries as well (Which also have post-build event commands that need to be run).

I would like this to happen when I click Start and not have to press Ctrl+Shift+B first to build everything (because I sometimes forget and wonder why the changes didn't happen).

If you have referenced the assemblies in your main app, they should be built automatically. If you don't have references, you can manually define project dependencies via

  • Click right on the solution
  • Select "Project Dependencies"
  • Define your main app to depend on all the assemblies you need to be built

Dependencies will only be built, if needed, ie if no file changed since last build, it won't be built.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM