Example 1
| The code is as follows |
Copy Code |
| var mytabs = new Ext.tabpanel ({ ID: ' Mytabs ', Region: ' Center ', Margins: ' 3 3 3 0 ', activetab:0, Border:false, Defaults:{autoscroll:true}, items:[ {layout: ' fit ', index:0, Border:false,id: "Customerinfotab", Items: [A], title: "The First"}, {layout: ' fit ', index:1, Border:false,id: "Havecartab", items: [b], title: "Second"} ] }); |
When an event is triggered. Hide the second, and then show the second one.
The method is as follows:
| The code is as follows |
Copy Code |
Mytabs. Hidetabstripitem (2); Hide Mytabs. Unhidetabstripitem (2); Show |
Example 2
| The code is as follows |
Copy Code |
var tabs = new Ext.tabpanel ({ activetab:0, Frame:false, Items: [Tab1, TAB2] });
Somewhere you need to hide tab1, show tab2
Tabs.tabbar.items.items[0].hide ();
Somewhere you need to show tab1
Tabs.tabbar.items.items[0].show (); |
A little bit.
1tabBar: Get all bar information on tab
Items&items[0] look at the picture
Items&items[0] Graphic Description _ Lazy People net _ lazy station
Well, you should understand, too,!!!!!!.