Posted on: 11/6/2012 12:06:54 AM | Views : 283

I have a finished asp.net mvc 4 app.
Now I’m writing a win forms version for desktop users.
I’ve successfully pushed most of the business logic into a class library and shared it between the two applications.
But I’m struggling with membership.
The mvc app uses the asp.net simple membership provider to manage users, roles, etc.
While I appreciate that some of this functionality is asp specific, logging on for instance which relies upon cookies, there is lots that is not, creating a user for instance.
So I hoped I could use the asp.net simple membership provider in my win forms app too.
But so far without success.
I have the connection strings configured in app.config but my call to WebSecurity.InitializeDatabaseConnection("<NameOfConnectionString>", "Users", "Id", "EmailAddress", autoCreateTables: true); fails with “The Role Manager feature has not been enabled.”
...

Go to the complete details ...