good day.
I was trying to set a background color of the data grid per row if this is possible in livecode.
here is my code i'm stuck on what next code will i enter. hope you can guide me
thanks in advance
Code: Select all
on mouseUp tMouseButton
   global tLineToSelect
   if  tMouseButton <> 1 then
      exit mouseUp
   end if
   
   put empty into tLineToSelect
   put the dgHilitedLine of group "SbCustOrderList" into tLineToSelect
   
   if tLineToSelect is not a number or tLineToSelect <= 0 then
      exit mouseUp
   else
      
      set the itemdel to tab
      put line tLineToSelect of the dgtext of grp "SbCustOrderList"  into tData
      FillInData
   end if
end mouseUp
on FillInData pData
   -- This message is sent when the Data Grid needs to populate
   -- this template with the column data. pData is the value to be displayed.
   
   set the text of me to pData
   SetForeGroundColor
end FillInData
 
 

