Page 2 of 2

Re: DataGrids... and printing...

Posted: Fri Oct 11, 2013 1:11 pm
by bangkok
Traxgeek wrote: If I want to override the row colour of a DG row (just for one (or more) specific row(s) within the full DG) how would I do that please ?
.
http://lessons.runrev.com/s/lessons/m/d ... -to-a-cell

->add a new invisible column, that will contain a flag (like to be colorized = 1 for instance)

->in the default column behavior :

[change]

Code: Select all

on FillInData pData
   set the text of me to pData
   SetForeGroundColor
end FillInData
[add]

Code: Select all

private command SetForeGroundColor
   if GetDataOfIndex(the dgIndex of me, "theFlag")=1 then
      set the textcolor of me to "black"
      set the backgroundColor of me to 68,234,45
      set the opaque of me to true
   else
      set the textcolor of me to "black"
      set the backgroundColor of me to "white"
      set the opaque of me to false
   end if
end SetForeGroundColor
A stack with some examples, to download :

http://forums.runrev.com/viewtopic.php? ... 540#p78299