saifullah khan

saifullah khan

  • NA
  • 335
  • 301.8k

statemanager is not saving userid after deploing the website

Mar 12 2014 3:42 AM
Hi everyone!
i have developed an asp.net application. in my login page(asp.net memebership) i have assigned the userrole to statemnager. here is the code in my login page
 if (!User_Exist1(StateManager.UserId))
{
e.Authenticated = false;
return;
}
else
{
e.Authenticated = true;
var CurrentCompany = string.Join(",", Roles.GetRolesForUser(CurrentUser.ToString()));
StateManager.UserRole = CurrentCompany.ToString();
Response.Redirect("Default.aspx");
}

For testing purpose i have assigned the StateManager.UserRole to a label in my default.aspx page
Label8.Text = StateManager.UserRole.ToString();in my un deployed version this is working fine. but when i deploy it. i does not work.

Can somebody please tell me whats wrong

thanks in advance