hi!<BR><BR> I have three columns in my sql server database namely<BR>username (char), password (char) and usertype (bit)<BR>now depending upon usertype i want to redirect the user when they log in either to admin page or normal page<BR>if the usertype is 0 i want to send them to admin page. if usertype is 1 i want to send them to normal page below is a working code if i change the usertype datatype to int<BR><BR>Private Sub btnLogin_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnLogin.Click<BR><BR> Dim reader As System.Data.SqlClient.SqlDataReader<BR> reader = myquery()<BR> Dim pageToGo<BR> While reader.Read()<BR> If (txtUname.Text = RTrim(reader.GetValue(0)) And txtPwd.Text = RTrim(reader.GetValue(1))) Then<BR> Session("login") = True<BR> Session("UserName") = txtUname.Text<BR> Session.Add("con", iasConnection)<BR><BR> If (RTrim(reader.GetValue(2)) = 1) Then<BR> pageToGo = "volunteer.aspx"<BR> Exit While<BR> &#039;ElseIf (reader.GetValue(2) = 0) Then<BR> &#039;pageToGo = "volunteer.aspx"<BR> &#039;Exit While<BR> Else<BR> pageToGo = "admin.aspx"<BR> Exit While<BR> End If<BR> Else<BR> Session("login") = False<BR><BR> pageToGo = "Login.aspx"<BR><BR><BR><BR> End If<BR> End While<BR> Response.Redirect(pageToGo)<BR> End Sub<BR><BR><BR>i know its a silly question but i can&#039;t help i spend all my nite please help me how to compare with bit value. thanks in forward.<BR><BR>cheers<BR>robin