Click here to Skip to main content
13,097,661 members (57,338 online)
Rate this:
 
Please Sign up or sign in to vote.
See more:
i have login page.if i login then it redirect to profile page..but i have search chart when i click on chart that time if i am not login user then i have to login and show the same page means searching chart...means i have redirect two different pages which is depending on condition.when i login whtever data in searching chart same data comes after login. plz help me?
Posted 27-Dec-12 23:59pm
Updated 28-Dec-12 0:21am
v3

1 solution

Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 1

You can use Session object for that, see here[^]..

Now, at the log in time, store your user name/ user id in one Session object like Session["Username"] = UserNameTxt.Text;
It makes Session.Count > 0, so you can use following scenario at Searching Chart:

if(Session.Count > 0)
{
    Response.Redirect("home.aspx");
}
else
{
    Response.Redirect("login.aspx");
}


Hope it will solve your issue.. :) If there is something that you don't get about this, let me know... :) :)
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


Advertise | Privacy |
Web02 | 2.8.170813.1 | Last Updated 28 Dec 2012
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100