caesardo
caesardo

Reputation: 346

multiple exe in bin folder after build solution

Is it possible to produce more than one exe in debug/release folder after we build Windows form solution?

For example I want to produce 2 exes in debug/release folder everytime I build a solution, 1. MyApp.exe 2. MyApp_setup.exe

Thanks

Upvotes: 1

Views: 3323

Answers (1)

Scott Chamberlain
Scott Chamberlain

Reputation: 127563

The \bin\Debug and \bin\Release folders are only defaults and can be changed in your project settings.

enter image description here (Click for larger view)

All you need to do is change it to a relative path to be something both projects can see.

For example, if your folder structure was like

C:\
 Code\
  MyAppSolution\
   MyApp\
   MyApp_Setup\

changing both projects to use ..\CommonBin\Debug\ as their output path would put both exe's in C:\Code\MyAppSolution\CommonBin\Debug\.


However there is a second option also, if you add a reference to the MyApp project to MyApp_Setup when you go to build MyApp_Setup it will put MyApp.exe in the output directory because it considered it a dependency. Just be sure you have Copy Local set to true when you build.

enter image description here

Upvotes: 7

Related Questions