1. #1
    Ext User
    Join Date
    May 2007
    Posts
    45
    Vote Rating
    0
    hui2008 is on a distinguished road

      0  

    Question About the tabpanel and grid question

    About the tabpanel and grid question


    Dear all,

    I create a tabpanel A, render grid B create tabpanel C, render grid D.

    I open tabpanel A and tabpanel B, if I close tabpanel B, the tabpanel A become blank, the grid B disappeared.

    who can tell me what's wrong with me?


    thanks!

  2. #2
    jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    Frederick MD, NYC, DC
    Posts
    16,360
    Vote Rating
    81
    jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all

      0  

    Default


    please post code!

  3. #3
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,503
    Vote Rating
    51
    Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    Why are you rendering? Don't you read documentation?

  4. #4
    Ext User
    Join Date
    May 2007
    Posts
    45
    Vote Rating
    0
    hui2008 is on a distinguished road

      0  

    Default


    The code like this:
    PHP Code:
    Ext.ux.showgrid Ext.extend(Ext.grid.EditorGridPanel, {
         
    layout:'fit'
        
    ,id:'showgird'
        
    ,border:false
        
    ,stateful:false
        
    ,initComponent:function(){
            
    this.viewConfig = {forceFittrue};
            
    Ext.apply(this,{
                
    sm:new Ext.grid.CheckboxSelectionModel()
            });
            
    Ext.ux.showgrid.superclass.initComponent.apply(thisarguments);
        }
    });
    Ext.reg(B,Ext.ux.showgrid);
    Ext.reg(D,Ext.ux.showgrid);

    this.add({
        
    id'tab-A',
        
    title'tabpanelA',
        
    closabletrue,
        
    items:[{xtype:B}]
    }).
    show();

    this.add({
        
    id'tab-C',
        
    title'tabpanelC',
        
    closabletrue,
        
    items:[{xtype:D}]
    }).
    show(); 

  5. #5
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,503
    Vote Rating
    51
    Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    DO NOT ADD A WRAPPER ROUND THE COMPONENT THAT YOU ARE ADDING!

    JUST ADD THE COMPONENT!


    Also, your code doesn't get to show the child items of a TabPanel.

    You ask the TabPanel to do that using setActiveTab

  6. #6
    jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    Frederick MD, NYC, DC
    Posts
    16,360
    Vote Rating
    81
    jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all

      0  

    Default


    Welcome back sir

  7. #7
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,503
    Vote Rating
    51
    Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    Perhaps I should hve come back under another username. Would you be able to tell I was back?

  8. #8
    Ext User
    Join Date
    May 2007
    Posts
    45
    Vote Rating
    0
    hui2008 is on a distinguished road

      0  

    Thumbs up


    Thank you very much, I try again

  9. #9
    jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    Frederick MD, NYC, DC
    Posts
    16,360
    Vote Rating
    81
    jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all

      0  

    Default


    Quote Originally Posted by Animal View Post
    Perhaps I should hve come back under another username. Would you be able to tell I was back?
    probably ... by the tone of the msgs, :P