PDA

View Full Version : simulate click on tab



joefox
25 Jun 2009, 9:51 AM
I have a hyperlink that i click, and it goes and get data via ajax, this fills in multiple div's with information.

My problem is...if i dont click on the tab first to see its contents, it put the contents right on the screen.

However, if i click on the tab, then go back to my normal tab and then get the data, it works fine.

So how do i simulate someon clicking through tabs?

tryanDLS
25 Jun 2009, 10:39 AM
Can't you just call setActiveTab(mytab)

joefox
26 Jun 2009, 6:07 AM
do i have to bind to the tab row first?

I use to use this

var myTabPanelReference = Ext.ComponentMgr.get('Administrator_Portal_Main') ;
myTabPanelReference.show();

but i cant get this object


},{
layout:'column',
title:'Teacher Roster',
id:'Teacher Roster',
iconCls:'group',
defaults:{
style:'padding:5px'
},
items: [{
title: 'Roster Details',
iconCls:'group',
columnWidth: .20,
autoScroll:true,
contentEl: 'Roster_Details',
height: 600,
minSize: 175,
maxSize: 600
},{
xtype: 'tabpanel',
id:'user_sub_panel',
activeTab:0,
columnWidth: .80,
height: 600,
minSize: 175,
items:[{
title:'Roster Management',
id:'Roster_Details',
iconCls:'user',
autoScroll:true,
contentEl: 'Roster_Details_Management'
},{
layout:'column',
title:'Roster Management - File Distribution',
id:'Roster_Details_File_Distribution12',
iconCls:'user',
defaults:{
style:'padding:5px'
},
items:[{
title: 'Your Home Drive Files',
iconCls:'user',
columnWidth: .35,
autoScroll:true,
contentEl: 'Roster_Details_File_Distribution',
height: 580,
tbar: [{
text: "Refresh File List",
iconCls: 'search',
handler: buildxmlofteacherhomedrive
},{
text: "Send Files",
iconCls: 'nav',
handler: teacherportalsendfiletostudents
}]
},{
title: 'Current Roster Students',
iconCls:'feedadd',
columnWidth: .65,
contentEl: 'Roster_Details_Management_File_Distribution',
height: 580
}]
}]
}]
}]

joefox
26 Jun 2009, 12:22 PM
anyone?