Ilia Lazarov

Ilia Lazarov

  • NA
  • 1
  • 8.4k

ASP.NET MVC 4 ADMIN PANEL

Nov 21 2012 3:22 PM
Hi Gurus,

First thanks to those who made this page. I am new to ASP and wanted to ask if there is info about MVC 4 creating admin panel.

there is so much info about MVC3 but none for MVC4 so if you can provide some help about it that would be great.

I have managed to edit the fields of the user and register him with additional info but i cannot edit it.

This is my code in brief:

if (ModelState.IsValid)
{
// Attempt to register the user
try
{
WebSecurity.CreateUserAndAccount(
model.UserName,
model.Password,
new {FirstName = model.FirstName,
LastName = model.LastName,
City = model.City,
ZIP = model.ZIP,
Street = model.Street,
StreetNumber = model.StreetNumber,
Country = model.Country}, false
);

WebSecurity.Login(model.UserName, model.Password);
return RedirectToAction("Index", "Home");
}
catch (MembershipCreateUserException e)
{
ModelState.AddModelError("", ErrorCodeToString(e.StatusCode));
}
}

// If we got this far, something failed, redisplay form
return View(model);
}

if anyone can provide some info about how to be able to create a panel that would be able to edit the user info would be very helpful.

Thanks in advance for any help.

Regards,
Ilia