1 TabStrip based on either of two others

5 posts, 1 answers
  1. Markus
    Markus avatar
    205 posts
    Member since:
    Nov 2005

    Posted 12 Apr 2013 Link to this post

    I have the following Setup

    TabStrip 1
    TabStrip 2

    TabStrip A
    TabStrip B

    If I click on a Tab in TabStrip 1 I populete TabStrip A + B
    If I click on a Tab in TabStrip 2 I populate TabStrip A + B 

    Now when I click on a Tab off TabStrip A or B I need to know if TabStrip 1 or TabStrip 2 populated the Tabstrips A + B

    ---------------

    Kind of  hard to explain.

    Look here to understand: http://uebersetzung.gebetsanliegen.ch/en/verse/default.aspx

    Left side bible books of Old Testament. If I click a book 1. Mose (Genesis) I populate TabStrip A with the available chapters and TabStrip B with the available verses in that chapter.

    Right side bible books of the New Testament. If i click on book Matthäus (Mathew)  I populate TabStrip A with the available chapters and TabStrip B with the available verses in that chapter.

    Now the problem is that when I click on a verse from TabStrip B - I need to know which TabStrip was used to populate (Old or New Testament)

    I could have TabStrips C + D and show hide when either TabStrip 1 or 2 is clicked but would like to have simple.

    Any idea how to have this done (all Ajax)

    Markus
  2. Answer
    Kate
    Admin
    Kate avatar
    1898 posts

    Posted 17 Apr 2013 Link to this post

    Hello Markus,

    One approach that you can use is to create a HiddenField on the server side and assign the ID of the clicked RadTabStrip to it. Then you can access this value and check which RadTabStrip is being clicked and the populate the desired RadTabStrip controls accordingly.  

    Greetings,
    Kate
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Markus
    Markus avatar
    205 posts
    Member since:
    Nov 2005

    Posted 17 Apr 2013 Link to this post

    Dear Kate

    That would probably be the easiest way :-)

    Markus
  5. Markus
    Markus avatar
    205 posts
    Member since:
    Nov 2005

    Posted 18 Apr 2013 Link to this post

    Dear Kate 

    Workes perfect with the hidden field. There is one last thing.

    When I click on the TabStrip1 I want all tabs of TabStrip2 deselected and the other way around.

    Is there a simple way to do it?

    http://uebersetzung.berchtold.net/en/verse/nasb.aspx

    If you click first a tab on the left side (old testament). Then when you click on the right side (new testament) then the selected tab on the left side should be deselected.

    Markus
  6. Kate
    Admin
    Kate avatar
    1898 posts

    Posted 22 Apr 2013 Link to this post

    Hi Markus,

    One approach that I can come up with is to go through the tabs collection and set the Selected property of the tabs to false. Thus, by clicking on RadTabStrip1, you can deselect all of the selected tabs in RadTabstrip2 and the other way around. Attached to this post you can find a very simplified runnable page that demonstrates the described approach.

    All the best,
    Kate
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017