Return to particular tab on redirect

5 posts, 0 answers
  1. Joe
    Joe avatar
    28 posts
    Member since:
    May 2007

    Posted 06 Jan 2010 Link to this post

    Hi!

    Got a page with multiple tabs on it and let's just say the user is on
    second tab which is company users where they can go on to create
    another user. When the user is created and they return back to the
    main page, I'd like to by default select the second tab which is the
    one they were on in the first place.

    Got this scenario popping up all over and just not sure what is best
    way of doing it? Had a look at FindTabByUrl but does not seem to
    do it for me...
  2. Christopher Bishop
    Christopher Bishop avatar
    50 posts
    Member since:
    May 2008

    Posted 07 Jan 2010 Link to this post

    Can't you just pass a query string back from the company page like
    ?backpage=companylist.aspx&tab=company
    After save redirect back to the "backpage"

    then when you load up your page that has all  the tabs go
    if request("tab") <> "" then

    radtabs.Tabs.FindTabByText(

    request("tab") ).Selected = True
    end if

    not pretty but I think that is what you are getting at yes?

     

  3. Joe
    Joe avatar
    28 posts
    Member since:
    May 2007

    Posted 07 Jan 2010 Link to this post

    Thanks Chris, but I was hoping there was a more elegant way of doing it...
  4. Christopher Bishop
    Christopher Bishop avatar
    50 posts
    Member since:
    May 2008

    Posted 07 Jan 2010 Link to this post

    Unless you are using ajax or setting a cookie/session I can't think of any other way to do it short of using a radwindow to do the edit.
  5. Joe
    Joe avatar
    28 posts
    Member since:
    May 2007

    Posted 10 Jan 2010 Link to this post

    Thanks, will go with that then!
Back to Top