Posted on: 7/30/2012 9:16:13 PM | Views : 1016

hi for all
i have login code in my master page
I want throw this code to check from user name
and password and usertype
admin or user
I try with this code he works in case of admin user
but another case
not work
this is my code 
SqlConnection conn = new SqlConnection(ConfigurationManager.ConnectionStrings["ContinueConnectionString"].ToString()); conn.Open(); string cn = "select UserName,Password,UserType from [users]"; SqlCommand cmd = new SqlCommand(cn, conn); SqlDataReader drr = cmd.ExecuteReader(); while (drr.Read()) { if (txtusername.Text == drr["UserName"].ToString() && txtpass.Text == drr["Pass ...

Go to the complete details ...