Hi there, IMHO, you first need to understand how the FormsAuthentication.RedirectFromLoginPage method works. Basically, the method will redirect the user to the originally requested page specified in the query string with the ReturnUrl key. If this key is not found, the user is always redirected to the Default.aspx at root. Here, you want to keep using this method, so IMO there are a couple of options come to mind: + If you want the user to be redirected to his originally requested page, you first check if the ReturnUrl key exists in the query string before calling the RedirectFromLoginPage. If the key does not exist, you can use the Response.Redirect method to go to the home.aspx page. If you don't want to do the checking, you can simply create a default.aspx at root, in this default page, you simply redirect the user to your home page home.aspx. + If you want the user to always be directed to the home.aspx page, you should use the Response.Redirect method instead of the FormsAuthentication.RedirectFromLoginPage. Or you can think of removing the ReturnUrl key in the query string with the sample code like this in the Page_Load event handler of the login page:
private void Page_Load(object sender, System.EventArgs e)
{
if(!IsPostBack && Request.QueryString["ReturnUrl"]!=null)
{
Response.Redirect(Request.Url.AbsolutePath);
}
}
For more information, see RedirectFromLoginPage [^]