I need to change the color of my rows in dojo data grid whenever I am editing. I tried dojo.connect
, however it works first time after that whenever I hover on other cells its automatically changing the colors of other row.
Does anyone know the solution for this issue?
You need to do following
1)CSS changes
.yellowishRow .dojoxGridCell {
background-color: #F3F781;
}
In your javascript
dojo.connect(dijit.byId("grid"),"onStyleRow",this,function(row){
var item = dijit.byId("grid").getItem(row.index);
if (item) {
var type = store.getValue(item, editMode, null);
if (type == "1") {
row.customClasses += ' regStartedRow';
}
dijit.byId("grid").focus.styleRow(row);
dijit.byId("grid").edit.styleRow(row);
});