PDA

View Full Version : error while hiding button group



smkkiran
28 Feb 2012, 11:53 PM
hi,
while i am trying to hide a buttongroup in a tool bar its showing 'Type mismatch.
vat btn=Ext.getCmp('btn_id');
btn.hide();'

can any one tell me what is wrong init. thanks in advance

mitchellsimoens
29 Feb 2012, 6:50 AM
What version are you using? I tried this in 4.0.7 and 4.1.0 beta3 and it works with no problems:


new Ext.container.ButtonGroup({
renderTo : document.body,
items : [
{
text : 'Hide Group',
handler : function(btn) {
var group = btn.up('buttongroup');

group.hide();
}
},
{
text : 'Two'
}
]
});