Nav w/User Control Issue: Link on ucHeader different events depending on page?

Discussion in 'ASP .Net Web Controls' started by JDP@Work, Apr 11, 2006.

  1. JDP@Work

    JDP@Work Guest

    Question: Is there a way to tell from what page the link was clicked from, if
    the link lives in a user control ?

    I have a ucHeader in .Net 2003 that has a linkbutton as well as a menu bar above
    with a home hyperlink.

    When on the main pg, the link dynamically displays "Go Up a Level"

    When on a "Show Rank" pg, it dynamically displays "Go Back" which on init of the
    Rank page sets the returnView = true

    I can see that the "sender" has a page value, {ASP.Main...} but I can't seem to
    capture that element.


    More Details.... follow:

    I've tried using a linkButton because it has server side events

    When the main page reloads and returnView = true, it uses the Last_Vars to
    requery and go back to where they left off.

    If the returnView was not set from the Rank page it is assumed (this may be the
    problem) that it's a "Go Up a Level" which simply renders the current view - 1

    Originally this was a javascript goback, but if one went in the following
    sequence...

    main --> down level on main --> "Up lvl" (javascript back) on main all was good,
    but....

    main --> Rank ---> main, "Up lvl" would be goback to Rank, which is bad.

    So, using the returnView differentiates either Go Up or Go Back.

    Again, the problem is that the hyperlink in the main menu calls the Main pg,
    which was just a reload of the top level, however now it assumes that since the
    returnView is nothing and curentView has a value that it must be currentView -1
    as in Up Lvl, rather than "TOP Level"

    If there was a way to know if I clicked the link from either the Rank or Main pg
    then I could set the go back or up conditions and also detect a top lvl as the
    lack of an up lvl.


    TIA

    JeffP....
     
    JDP@Work, Apr 11, 2006
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?Sko=?=

    Page Nav

    =?Utf-8?B?Sko=?=, Oct 6, 2004, in forum: ASP .Net
    Replies:
    4
    Views:
    451
    Patrick.O.Ige
    Oct 7, 2004
  2. Kit
    Replies:
    0
    Views:
    340
  3. Chris

    Events Events Events Please Help

    Chris, Aug 30, 2005, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    371
    Chris
    Aug 30, 2005
  4. Lois
    Replies:
    2
    Views:
    135
  5. Martin Lira

    Highlight left nav based on user position

    Martin Lira, Feb 1, 2005, in forum: Javascript
    Replies:
    1
    Views:
    91
    Fred Oz
    Feb 2, 2005
Loading...

Share This Page