Last post May 25, 2020 08:51 AM by YihuiSun
May 23, 2020 05:13 AM|TheNutCracker|LINK
I'm creating a new WebApplication using Visual Studio 2019 and choosing MVC as the project template and selecting the option to use local accounts.
When I debug the application, the Login() method of the AccountController is throwing NullReferenceExceptions. I haven't added any of my own code. Does Microsoft know this?
It's kinda weird because the webpage for the Login.cshtml view will load just fine in the browser. You'll only see the NullReferenceExceptions if you're debuggint the Login() method of the AccountController.
May 23, 2020 05:43 PM|bruce (sqlwork.com)|LINK
You have probably set vs to stop on caught exceptions. That is you are breaking on an error that is handled by default and is expected.
May 23, 2020 07:37 PM|TheNutCracker|LINK
Yes, I agree. But my question had to do with why exceptions would even be thrown by default Microsoft code that ships this way from the factory, so to speak? Is that proper? That's the bizarre point. It's what my whole question revolves around. Why ship,
or even, encourage, code that produces exceptions?
May 25, 2020 08:51 AM|YihuiSun|LINK
I created the Identity project and debug it. There is no problem. Can you give a screenshot of your problem or describe it more specifically?