0

我有一个窗体,我需要在满足条件时禁用它。

if (conditionIsMet){

        var theFormPanel= Ext.ComponentQuery.query('#winId> #theFormPanel')[0];


}

但我怎样才能禁用它?

4

1 回答 1

3
if (conditionIsMet){
  var theFormPanel= Ext.ComponentQuery.query('#winId> #theFormPanel')[0].disable();
}

为什么在这里使用 ComponentQuery 查询?你不能通过id获取formpanel吗?Ext.getCmp('formPanelId').disable();

于 2012-11-18T10:57:58.183 回答