If Statement...

Results 1 to 3 of 3

Thread: If Statement...

  1. #1
    Join Date
    Dec 1969

    Default If Statement...

    OK, im banging my head against the wall now.<BR><BR>I have the following code which seemed very simple:<BR><BR>If Not rs("UID") = Request.Cookies("ID") Then<BR> Response.Redirect("error.asp?Type=Access")<BR>End If<BR><BR>However, no matter if the two values are equal or not it ALWAYS redirects to the error page.<BR><BR>All i need it to do is if they arent equal then to send the user off to the error page.<BR><BR>It must be late :(

  2. #2
    Join Date
    Dec 1969

    Default Why not do something simpler:

    If clng(rs("UID")) &#060;&#062; clng(Request.Cookies("ID"))<BR><BR>

  3. #3
    Join Date
    Dec 1969

    Default Or you may try this as well...

    If (Not rs("UID") = Request.Cookies("ID")) Then <BR> Response.Redirect("error.asp?Type=Access") <BR>End If <BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts