Frage

I am aware of old membership and familiar with aspnet_regsql.exe concept. Now I'm using asp.net MVC4.0 (Visual Studio 2013). How do I get new simple membership table of MVC 4.0 in SQL server management studio.

War es hilfreich?

Lösung

The tables are created automatically the first time you try to register a user.
so if you want to access those table via SQL server,you need create one database in sql server and replace default connection string in web.config with (new database) connection string. so now membership table will created in your new database

See this link.

Andere Tipps

if I understand you correctly, you need to using InitializeSimpleMembershipAttribute where most interest is the following code

WebSecurity.InitializeDatabaseConnection("EFDBContext", "UsersTable", "UserId", "Login", autoCreateTables: true);

Where: - EFDBContext (connection string name)

after which all the necessary tables will Create, in particular

webpages_Membership

webpages_Roles

webpages_UsersInRoles

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top