DataView cell color

Is it possible to set the cell color for an element in the DataView after its loaded. Much like setRowColor from the grid.

Thanks!

template allows to define any styles and content you need. Please see the sample:

dhtmlxDataView/samples/02_templates/02_js.html

Yes, but after the thing is loaded can I apply a new template? I simply want to load things up and then change the background colors as needed just like setRowColor.

You need to define the new template or assign new property that is already used in the template and call refresh(id) method to redraw an item:

{

template:function(obj){
if(obj.color)
return “”+obj.text+"";
reutrn obj.text;
}

}

dataview.get(id).color = “blue”;
dataview.refresh(itemId);