Hi there,
Is there any methods that we can call to lose focus from a grid?
The issue we are facing is:
1. Have two grids (jqxGrid1 and jqxGrid2) on the same page.
2. Focus and select a cell ([firstName]) on jqxGrid1 after loading.
3. When select cells from a certain column ([total]), unselect that cell from jqxGrid1, and switch focus to jqxGrid2 and select a cell ([firstName]).
Both grids are editable using selection mode ‘multiplecellsadvanced.’ However, jqxGrid2 cannot be edited using keyboard directly without mouse focus first.
The issue seems to be from confusing focus between these two grids. Any idea? Thanks!
Some code snippet as below:
$("#jqxGrid1").on('cellselect', function (event) {
var dataField = event.args.datafield; // column data field.
var rowBoundIndex = event.args.rowindex; // row's bound index.
if (dataField == 'total') {
$('#jqxGrid1').jqxGrid('unselectcell', rowBoundIndex, dataField);
$('#jqxGrid1').jqxGrid({ disabled: true });
$('#jqxGrid2').jqxGrid('focus');
$('#jqxGrid2').jqxGrid('selectcell', 0, "firstName");
}
});