Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Fabio on Mar 30, 2008 10:03
open dhtmlx forum
single cell color

Hi,
I'd like to change only one cell color into XML...

<rows>
<head>
...
<column width="250" type="ro" align="left" color="white" sort="str">Title</column>
...
</head>
<row id="1">
<cell>name1</cell>
</row>

<row id="2>
<cell style="background-color: red">name2</cell>
</row>

<row id="3">
<cell>name3</cell>
</row>
...
</rows>

why this doesn't work?

thx,
Fabio

Answer posted by Support on Mar 31, 2008 02:50
The problem was not reconstructed locally.

Please, see attached sample.
Attachments (1)
Answer posted by Fabio on Mar 31, 2008 03:49

your example works.

with my dhtmlxTreeGrid_v14_Pro_70813 not.

could you send me an update for dhtmlXGrid.js ?

 

thx,

Fabio

Answer posted by Support on Mar 31, 2008 05:01
dhtmlxgrid 1.4 buil 70813 doesn't support "style" attribute of cell tag, but you can use "class" attribute for similar purpose.

In HTML
<style>
     .my_red{
       background-color:red;
    }
</style>

In XML
<row id="2>
    <cell class="my_red">name2</cell>
</row>
Answer posted by Fabio on Mar 31, 2008 05:24

works!

 

Thank  you!

Fabio