MVC 3 "parameterless constructor defined for this object."

While working on my MVC 3.0 project i got this shocking error when i put my grid and a BeginForm() on the same page while i was passing a List of my model to the View. so here are some steps that i do and get it fixed.

1. Add and empty constructor to your Model


public class MyModel
    {

         ////Constructor of MyModel Class

              public MyModel()
                 {
                  }
        /// End constructor


    }

Comments

Popular Posts

GREYCstoration Oil Paint plugin for Photoshop

Apple iPhone sending SMS automatically 00447786205094

SharePoint online hub navigation not updating for other users

Service Bus Gateway service stuck at Starting

RangeError: Maximum call stack size exceeded | Node JS | SPFX React