Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
495
Want to set focus on Infragistics.WebUI.UltraWebTab and need to open it by pressing enter,,,
posted

Hi All,

I have three WebUI.UltraWebTabs like Tab1,Tab2.Tab3.

I want to set focus on each tab header by tabbing and once tab focus reach one of the tab's header it should open by pressing enter button.

Please guid me for this.

Regards,

Varun

Parents
No Data
Reply
  • 12004
    posted

    Hello Rob,

    To open a tab programatically you can use one of the utility functions (igtab_getTabById) and pass in the UltraWebTab's id as a parameter. So for example the UltraWebTab can be setup in the markup like this:

    <igtab:UltraWebTab ID="UltraWebTab1" runat="server">
        <Tabs>
            <igtab:Tab Key="Tab1" Text="Tab1">
                <ContentTemplate>
                    Test 1
                </ContentTemplate>
            </igtab:Tab>
            <igtab:Tab Key="Tab2" Text="Tab2">
                <ContentTemplate>
                    Test 2
                </ContentTemplate>
            </igtab:Tab>
            <igtab:Tab Key="Tab3" Text="Tab3">
                <ContentTemplate>
                    Test 3
                </ContentTemplate>
            </igtab:Tab>
        </Tabs>
    </igtab:UltraWebTab> 

    Each tab can be created and assigned as a key.

    In Javascript to set the selected tab would be to retrieve a tab object using the function tabFromKey. In the markup specified contains a key for each tab. Here's an example on opening the 2nd tab programatically:

    var UltraWebTab = igtab_getTabById('UltraWebTab1');
    var tab2 = UltraWebTab.tabFromKey('Tab2');
    UltraWebTab.setSelectedTab(tab2);

    Let me know if this works for you.

    Sincerely,
    Duane Hoyt
    Developer Support Engineer, MCTS
    Infragistics
    http://es.infragistics.com/support

Children