Jun 13, 2016, 9:58 AM
Enable gridpanel command column button
I have used preparetoolbar disable command button and it works fine
<PrepareToolbar Fn="prepareToolbar"/>
var prepareToolbar = function (grid, toolbar, rowIndex, record) {
var firstButton = toolbar.items.get(0);
firstButton.setDisabled(true);
firstButton.setTooltip("Disabled");
}
but If I want to use SelectionChange to enable command button got error "Uncaught ReferenceError: App is not defined" <SelectionChange Fn="onSelectionChange" />
var onSelectionChange = function (grid, selection) {
App.gridCommandCol.commands[0].disabled = false;
App.GridPanel.reconfigure();
}