Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by David Charron on Oct 08, 2009 11:21
open dhtmlx forum
Is there a way to change the group header color in dhtmlxGrid?

Hi,

I'd like to know if there is a way to dynamically change a specific group header background color (depending on a certain condition)?

Thank you.
Answer posted by Stanislav (support) on Oct 09, 2009 08:35
API allows to control only text content of the cell , but doesn't give access to the container styling
You can exploit html rendering ability, by using

grid.customGroupFormat = function(group_name, count){
    return "<div style="width:100%; background-color:red;">any text</div>";
}