I am using MVC4 with the default membership provider and using entity framework code first. The membership data is in a database stored in my app_data folder called aspnet-xxxxxx.mdf, and my application data is created in a separate database running on SQL Server express.
What do I have to do so that I have 1 database containing my membership tables and the application data? I do not mind losing the data in either of these databases as at the moment it is only test data.
Find your InitializeSimpleMembershipAttribute.cs and change in the line
WebSecurity.InitializeDatabaseConnection("[ConnectionString]", builder.Provider, "UserProfile", "UserId", "UserName", autoCreateTables: false);
[ConnectionString]
to your connection string name you defined in Web.config. Or provide a complete connection string
Collected from the Internet
Please contact [email protected] to delete if infringement.
Comments