[CLOSED] Hiding/Showing tabs in TabPanel during DirectEvent

Page 1 of 2 12 LastLast
  1. #1

    [CLOSED] Hiding/Showing tabs in TabPanel during DirectEvent

    I have a panel within a TabPanel that is hidden on the initial page load. During a DirectEvent, I'm trying to show this tab. I've tried changing the Visible and Hidden properties, but nothing seems to work.

    How can I do this?
    Last edited by geoffrey.mcgill; Jul 15, 2010 at 10:19 PM.
  2. #2
    Hi,

    Hidden tab is excluded from TabPanel therefore you have to readd it to TabPanel

    JS code
    TabPanel1.addTab(Tab2);
    Please see the following sample (Tab6 and 'Show Tab6' button)
    https://examples1.ext.net/#/TabPanel/Basic/Show_Hide/
  3. #3
    How would I do that from the serverside?
  4. #4
    Hi,

    Just register that script on the client side
    TabPanel1.Call("addTab", new JRawValue(Tab2.ClientID))
  5. #5
    I'm getting this javascript error:

    Error: 'hidden' is null or not an object

          <ext:TabPanel ID="Tabs" runat="server" Border="false">
                <Items>
                    <ext:Panel ID="StuffPanel" runat="server" Title="Stuff">
                        <Content>
                            STUFF
                        </Content>
                    </ext:Panel>
                    <ext:Panel ID="AnotherPanel" runat="server" Title="Other Stuff" Hidden="true">
                        <Content>
                            THIS IS HIDDEN INITIALLY
                        </Content>
                    </ext:Panel>
                </Items>
            </ext:TabPanel>
                Tabs.Call("addTab", New JRawValue(AnotherPanel.ClientID))
  6. #6
    Hi,

    What is 'hidden'? Is that a function or property you are trying to set? or generated from Ext.NET?

    Can you post a full code sample demonstrating the whole scenario? It's tough to tell what might be going wrong just based on those limited code snippets which do not show all the moving parts.
    Geoffrey McGill
    Founder
  7. #7
    'hidden' isn't anything that I've set. I have the Hidden attribute set on the panel, but that's all.
  8. #8
    Quote Originally Posted by jmcantrell View Post
    'hidden' isn't anything that I've set. I have the Hidden attribute set on the panel, but that's all.
    Ok, thanks for the update. We'll wait for your sample demonstrating how to reproduce.
    Geoffrey McGill
    Founder
  9. #9
    I think it may have been something within the tab that was causing that message. How can I make the tab appear at a specific spot in the tab bar? In the markup, it's positioned in the middle, but when calling addTab(), it's moved to the end.
  10. #10
    Hi,

    Second argument for the addTab method is index. Please see the sample which I mentioned before ('Show Tab3 at begin' button)
Page 1 of 2 12 LastLast

Similar Threads

  1. [CLOSED] Problem hiding/showing controls
    By tlfdesarrollo in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: May 29, 2012, 3:37 PM
  2. [CLOSED] Hiding/showing Tabpanel buggy
    By mirwais in forum 1.x Legacy Premium Help
    Replies: 5
    Last Post: Mar 14, 2012, 11:26 AM
  3. [CLOSED] Problems with layouts after hiding/showing
    By jmcantrell in forum 1.x Legacy Premium Help
    Replies: 12
    Last Post: Jul 29, 2011, 3:53 AM
  4. [CLOSED] TabPanel tabs are not hiding
    By rnachman in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: Mar 31, 2011, 11:22 PM
  5. Hiding and Showing up a TapPanel
    By pearl in forum 1.x Help
    Replies: 0
    Last Post: Mar 11, 2009, 8:27 AM

Posting Permissions