[CLOSED] Tab Panel reload

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1

    [CLOSED] Tab Panel reload

    Hi,

    I need to reload the content of a couple of tabs on the page on the ComboBox Select direct event. My server code looks similar to this:

            protected void ComboInvestigators_Select(object sender, DirectEventArgs e)
            {
                var tab1 = this.TabPanel1.Items.FirstOrDefault<Component>(comp => comp.ID.Equals("tab1"));
                if (tab1 != null)
                    (tab1 as Ext.Net.Panel).Reload();
    
                var tab2 = this.TabPanel1.Items.FirstOrDefault<Component>(comp => comp.ID.Equals("tab2"));
                if (tab2 != null)
                    (tab2 as Ext.Net.Panel).Reload();
            }
    The markup for the TabPanel with the Listener:

                <ext:TabPanel ID="TabPanel1" runat="server" Region="Center"
                    EnableTabScroll="true">
                    <Items>
                        <ext:Panel ID="tab1" runat="server" Title="Tab 1">
                            <AutoLoad Mode="IFrame" Url="~/TabPage1.aspx" ShowMask="true" />
                            <Listeners>
                                <Activate Handler="PanelExplorer.layout.setActiveItem(#{MenuPanel1});
                                                    PanelExplorer.items.each(function (item) {
                                                        if (item.menu.rendered) {
                                                            item.clearSelection();
                                                        }
                                                    });
                                                    PanelExplorer.getComponent('MenuPanel1').setSelection(#{mnTab1});" Delay="1" />
                            </Listeners>
                        </ext:Panel>
                    </Items>
                </ext:TabPanel>
    The first tab is static while others are created dynamically. This works fine when the reloaded tab panel is the selected panel. Otherwise, inactive tab panels display distorted and partially loaded content after reloading that way. Please suggest a solution to the issue.

    Edit in: While we are at it, the server side TabPanel1.Items don't contain any dynamically created in Javascript tabs. What's the right way to access those tabs in the direct event?

    Thanks,

    Vadym
    Last edited by Daniil; May 30, 2012 at 6:38 PM. Reason: [CLOSED]

Similar Threads

  1. [CLOSED] reload usercontrol in panel & checkbox
    By nhg_itd in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Oct 10, 2011, 8:46 AM
  2. Grid Panel Reload
    By karthik.arian03 in forum 1.x Help
    Replies: 6
    Last Post: Feb 17, 2011, 11:31 AM
  3. [CLOSED] Efficient Panel Reload
    By macap in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: Oct 25, 2010, 2:25 PM
  4. [CLOSED] Reload an iframe within a panel
    By jeremyl in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Nov 05, 2009, 12:55 PM
  5. Reload central panel content
    By Dgsoft.ru in forum 1.x Help
    Replies: 1
    Last Post: Apr 08, 2009, 6:34 AM

Tags for this Thread

Posting Permissions