public ActionResult SignUp( UserBO objUserBO )
{
if (ModelState.IsValid)
{
UserBL objUserBL = new UserBL();
if(objUserBO.UserId >= 1)
{
nsrouteEntities.Entry(objUserBL).State = EntityState.Modified;
}
else
{
CustomBO objCustomBO = objUserBL.AddUser(objUserBO);
return View("Login");
}
}
return View(objUserBO);
}
for the bold part the below error is coming
object reference is required for the non static field,method or property
the form is opening properly but when we submit the form it is adding a new record instead of upadating the existing record