This fires on an Load event
If Session("PassP") = Session("Passgaro") Then
'open page ("Admin.aspx") not as redirect or transfer that will fires this query again and again on the load event,
'but skip the load event cause the condition is met.
End
Else
Server.Transfer("Default.aspx")
End If
Go to the complete details ...