skip to Main Content

Passing ID from View to Controller (ASP.NET)

I'm getting the following error: System.NullReferenceException: 'Object reference not set to an instance of an object.' Microsoft.AspNetCore.Mvc.Razor.RazorPage.Model.get returned null. I'm trying to pass an Id from a view to a controller HttpPost action method. Here is my code: Controller: public…

VIEW QUESTION
Back To Top
Search