A project with an Output Type of class Library cannot be started directly. In order to debug this project, add an executable project to this solution


In this tutorial you will learn how to solve this error A project with an Output Type of class Library cannot be started directly. In order to debug this project, add an executable project to this solution which references the library project. Set the executable project as the startup project. Once I tried to debug my web based asp.net project then I got this error. I solved it. Let's have a look over its solution.
The solution is quite simple and consists of two steps given below.

  1. Right Click on your project -> and click on Set as StartUp Project
  2. Right click on your .aspx file from where you want to start your debugging, like login.aspx and click on Set As Start Page and that’s it.

So this is the way to get rid of this A project with an Output Type of class Library cannot be started directly. In order to debug this project, add an executable project to this solution which references the library project. Set the executable project as the startup project nasty error.

1 comments:

  • Anonymous
     

    thankx it worked for me!