Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Ale on Jun 26, 2008 14:21
open dhtmlx forum
Cell Colour

Is it possible to change the colour of an unique cell without lose the data on it? (withou CP cell)

I need to display TV grid information, and must show with the same colour if it same TV program.

eg. PROGRAM "A" starts at 0:00 AM and ends at 01.30 A.M.

(1 row per half hour)

Monday Thuesday
00:00 Program A
(in Green)
00:30 Empty. (in Green)

01:00 Empty. (in Green)

01:30 Program B
(other colour)
...
02:00
Answer posted by Support on Jun 27, 2008 02:49
From js code, color of row can be set as
    grid.setCellTextStyle(row_id,column_index,"background-color:red;")

Or it can be specified as part of XML
    <row id="some">
       <cell style="background-color:red;">Red here</cell>
       <cell style="background-color:green;">Green here</cell>
    </row>