Hello,
I have this strange problem with redirecting my user to a certain page depending on their role.
When I fill in my username and password for a mechanic for example i have to be redirected to mechanics.aspx, but this does not happen.
The first time I am redirected to the default.aspx page, when I click the back button in the browser and I fill in again username and password for a mechanic
I am redirected to mechanics.aspx which is right. It's always the first time. In my page_load event handler i have the following:
if(User.IsInRole("Mechanics"))
{
Response.Redirect("mechanics.aspx");
}
When i put a break point on the if statement the first time when I am redirected to the default page User is always empty.
Does somebody know what is the problem or has experienced it self. ...
Go to the complete details ...