Page Redirect
-
Hi all, I want to redirect to the called page(aaa.aspx) after i logged in.By default i redirected to some other page(bbb.aspx).How to redirect to the called page .Please help me..
Response.Redirect("aaa.aspx",false);
Vuyiswa Maseko, Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers." C#/VB.NET/ASP.NET/SQL7/2000/2005/2008 http://www.vuyiswamaseko.com vuyiswa@its.co.za http://www.itsabacus.co.za/itsabacus/
-
Hi all, I want to redirect to the called page(aaa.aspx) after i logged in.By default i redirected to some other page(bbb.aspx).How to redirect to the called page .Please help me..
Try To add the code in
protected void Login1_LoggedIn(object sender, EventArgs e)
{
Response.Redirect("yourPage.aspx");
}MyFirstArticle MenuControlSelectedItem Why Do Some People Forget To Mark as Answer .If It Helps.
-
Response.Redirect("aaa.aspx",false);
Vuyiswa Maseko, Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers." C#/VB.NET/ASP.NET/SQL7/2000/2005/2008 http://www.vuyiswamaseko.com vuyiswa@its.co.za http://www.itsabacus.co.za/itsabacus/
-
I guess, the question is "how to redirect to the requested page instead of default page after login?"
- Regards -
J O N
A good thing is a bad thing if it keeps you from the best thing. - Dr. Adrian Rogers
What is wrong with the answer i gave ?
Vuyiswa Maseko, Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers." C#/VB.NET/ASP.NET/SQL7/2000/2005/2008 http://www.vuyiswamaseko.com vuyiswa@its.co.za http://www.itsabacus.co.za/itsabacus/
-
Hi all, I want to redirect to the called page(aaa.aspx) after i logged in.By default i redirected to some other page(bbb.aspx).How to redirect to the called page .Please help me..
check for
Request.QueryString["ReturnURL"] != null
to redirect to the requested PageURLif (Request.QueryString["ReturnUrl"] != null)
{
Response.Redirect(Request.QueryString["ReturnUrl"]);
}
else
{
Response.Redirect("default.aspx");
}- Regards -
J O N
A good thing is a bad thing if it keeps you from the best thing. - Dr. Adrian Rogers
-
Hi all, I want to redirect to the called page(aaa.aspx) after i logged in.By default i redirected to some other page(bbb.aspx).How to redirect to the called page .Please help me..
I would recommend to use
Server.Transfer
from aaa.aspx. :)Abhishek Sur
My Latest Articles **Create CLR objects in SQL Server 2005 C# Uncommon Keywords Read/Write Excel using OleDB
**Don't forget to click "Good Answer" if you like to.
-
I would recommend to use
Server.Transfer
from aaa.aspx. :)Abhishek Sur
My Latest Articles **Create CLR objects in SQL Server 2005 C# Uncommon Keywords Read/Write Excel using OleDB
**Don't forget to click "Good Answer" if you like to.
-
All :thumbsup:The Best
MyFirstArticle MenuControlSelectedItem Why Do Some People Forget To Mark as Answer .If It Helps.
-
Yes. This is cool. But seems that you gave me "Bad Answer". Is there any reason for that. I think if you are in a page already you dont need to Redirect again. :laugh:
Abhishek Sur
My Latest Articles **Create CLR objects in SQL Server 2005 C# Uncommon Keywords Read/Write Excel using OleDB
**Don't forget to click "Good Answer" if you like to.
-
What is wrong with the answer i gave ?
Vuyiswa Maseko, Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers." C#/VB.NET/ASP.NET/SQL7/2000/2005/2008 http://www.vuyiswamaseko.com vuyiswa@its.co.za http://www.itsabacus.co.za/itsabacus/
It doesn't help at all. He wants his page to redirect to the login, and then whatever page the user went to, it goes back to.
Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.