Hi Max,
Nahid has given you a typical code snippet on how to programmaticall y do
the membership user validation and FormsAuthentica tion Login operations.
Actually, for the FormsAuthentica tion and User validation in ASP.NET 2.0,
it consists of two parts:
1. Use membership API to validate the user's username/password credentials
2. All FormsAuthentica tion API to logon(generate and set authentication
ticket/cookie).
Here are some further articles introducing the model of ASP.NET
formsauthentica tion and membership service and how they work together:
#Explained: Forms Authentication in ASP.NET 2.0
http://msdn2.microsoft.com/en-us/library/aa480476.aspx
#Examining ASP.NET 2.0's Membership, Roles, and Profile - Part 1
http://aspnet.4guysfromrolla.com/articles/120705-1.aspx
If you have any further specific questions on this, please feel free to
post here.
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.