After lot of research and attempts I failed, here is the situation :
Technologies
- Asp.Net MVC4
- Entity Framework Code First
- SQL Server 2008
I used Code First to create my domain classes, example :
public class Country{
public int IdCountry {get;set;}
public int NameCountry {get;set;}
}
public class Sex{
public int IdSex {get;set;}
public int NameSex{get;set;}
}
etc... I have like 20 classes
All I want is :
Use the Asp.Net Membership system, and plug it to my classes. I have a domain class called UserProfile
public class UserProfile{
public int IdUserProfile {get;set;}
public virtual Sex sex {get;set;}
public virtual Country country {get;set;}
public virtual ICollection<Photos> photos {get;set;}
etc...
}
I want to be able to connect all this with the Asp.Net User registered via Asp.Net Membership and the AccountController
I search in stackoverflow, codeplex etc.. and I dont find a solution for that or perhaps I did not understand.
I hope someone have achieved this in real world application :)
ps : I am working on a "dating" Website