0

If I right click on a project in Solution Explorer, and select Debug->Start New Instance, then the compiler kicks in getting everything ready to run. Good work so far.

However if during that compile I click within a source file that I happen to have open for editing, then the debugger attempts to launch the project that contains said source file! Usually this results in it complaining that it can't launch a class of type library.

If I sit and wait patiently for the compiler to complete before launching then all is well. But that's a bit annoying if I want to read some other code whilst it's compiling.

I'm working with C# and C++ in case that's important - you never know!

Update

The application that I want to launch is also selected as the startup project. But then that shouldn't actually matter if I specifically select the application to be started.

LordWilmore
  • 2,829
  • 2
  • 25
  • 30
  • 1
    What is your startup project? (Which project is in bold font). It has to be a web app or an executable – Mark C. Jan 25 '16 at 13:02
  • 7
    Might be worth looking at "[A project with output type of class library cannot be started directly - with a startup exe](http://stackoverflow.com/q/757010/1364007)" - seems like the same problem. I've had this before, BTW. – Wai Ha Lee Jan 25 '16 at 13:02
  • That's the one! I'll go and read over there. Thanks! – LordWilmore Jan 25 '16 at 13:05

1 Answers1

0

right click solution on solution explorer;

>> Common Properties
>>>> Startup Project 

probably "Current selection" is selected . select other one of items

Wai Ha Lee
  • 8,598
  • 83
  • 57
  • 92
levent
  • 3,464
  • 1
  • 12
  • 22
  • No, read the question again. Also Wai Ha Lee has already provided links to sites telling me that this is a common issue. – LordWilmore Mar 01 '16 at 11:14