Can't get the OWIN Startup class to run in IIS Express after renaming ASP.NET project file

后端 未结 2 924
没有蜡笔的小新
没有蜡笔的小新 2020-12-07 04:49

I\'ve got a situation where I needed to change the solution and project names within a OWIN-based WebAPI website. Everything worked great before this change, and to my knowl

相关标签:
2条回答
  • 2020-12-07 05:44

    While I can't fully explain why this solves the issue, I was able to fix this by changing my projects to build to the regular bin/ folder.

    I apologize for not mentioning this in my original question, because I didn't think it was relevant, but I had previously changed my ASP.NET project to build to bin\Debug and bin\Release depending on the configuration. This seemed to work just fine, but caused this issue once I changed the name of the projects.

    0 讨论(0)
  • 2020-12-07 05:49

    I know this is old, but just wanted to add that I ran across this using a custom template. In my case I had a working solution with a startup, made it a template but the template didn't work.

    Come to find out, it was because the new project had a space in its name. So adding

    [assembly: OwinStartup(typeof(myProjectName.Startup))]
    

    to my existing startup file fixed it.

    0 讨论(0)
提交回复
热议问题