Aug 05, 2010, 8:07 AM
How to close tabpanel's tab in other window
Hello. I heve next problem:
I have page with treepanel. When I'm clickin in the tree element will open new tab:
At the update_student.aspx pade I have button. When I'll click on it will close created tab.
How can I do this operation? Help me, please.
I have page with treepanel. When I'm clickin in the tree element will open new tab:
function addTab(tabPanel, id, title, url) {
var tab = tabPanel.getComponent(id);
if (!tab) {
tab = tabPanel.add({
id: id,
title: title,
closable:true,
autoLoad: {
showMask: true,
mode:'iframe',
url: url
},
listeners: {
update: {
fn: function(tab, cfg) {
cfg.iframe.setHeight(cfg.iframe.getSize().height - 20);
},
scope: this,
single: true
}
}
});
}
tabPanel.setActiveTab(tab);
}
<Listeners>
<Click Handler="addTab(#{CenterPanel},'IdPeopleNew','test tab', 'update_student.aspx');" />
</Listeners>
At the update_student.aspx pade I have button. When I'll click on it will close created tab.
How can I do this operation? Help me, please.
Last edited by geoffrey.mcgill; Aug 05, 2010 at 7:17 PM.
Reason: please use [CODE] tags