No owin.Environment item was found in the context

前端 未结 12 1850
心在旅途
心在旅途 2020-12-10 00:44

Microsoft recently introduced new ASP.NET Identity - replacement for old (Simple)Membership. Unfortunately, I can\'t use this new membership system in my old project because

12条回答
  •  长情又很酷
    2020-12-10 01:19

    I had the exact same error, but as it turned out I had another configuration problem in my web.config. My web.config was missing the attribute defaultLanguage="c#" in the compilation element under system.web.

    In this case it will default to VB. So unless you have your Startup class written in VB you should change the default language to C#.

    Not correct:

    
    

    This is correct (unless you use VB):

    
    

提交回复
热议问题