I have a situation where, if I edit Cell1
, UI Grid will run validators for Cell1
, but I also want to run the validators for Cell2
.
If Cell2
value is not proper then I want to set focus on Cell2
with validation message set in uiGridValidateService.setValidator()
.
I am able to run the validator for Cell2
on Cell1
edit using below statement, but not able to highlight Cell2
.
Code:
gridApi.grid.validate.runValidators(rowEntity, colDef, rowEntity['Cell2'], NaN, $scope.gridApi.grid);
How can I put focus on a particular cell in UI Grid?