Question: Today I noticed that new MVC projects in VS 2012 are using [WebMatrix.WebData.WebSecurity](http://msdn.microsoft.com/en-us/library/webmatrix.webdata.websecurity%28v=vs.99%29.aspx) to handle membership related tasks.

I went to msdn to a quick look at the documentation and was surprised. Lot's of good stuff in there and it will definitely save me a lot of time in future projects.

But one thing got my attention:
It doesn't have a function to "Remove Accounts". Is there a particular reason for that? Should I use the underlying membership provider to remove accounts (and other things such as unlock accounts)?

Answer: 
Found the answer at MSDN:
<http://msdn.microsoft.com/en-us/library/webmatrix.webdata.simplemembershipprovider%28v=vs.111%29>

> 
> In ASP.NET Web Pages sites, you can access the functionality of the SimpleMembershipProvider class by using the Membership property of a web page. You do not (in fact, cannot) initialize a new instance of the SimpleMembershipProvider class...
> 
> 
>
`((SimpleMembershipProvider)Membership.Provider).DeleteAccount("UserName");` //This will remove entry from **[webpages\_Membership]** table

`Roles.RemoveUserFromRole("UserName", "RoleName");` // This will remove from **[webpages\_UsersInRoles]** table

`((SimpleMembershipProvider)Membership.Provider).DeleteUser("UserName", true);` // This will remove from **userprofile** table