Thanks a lot Dmitry for the highlight........
I was putting the script in wrong place. The following seems to be working OK:
//Coloring tgrid WHOLE row boolean and comboboxes
procedure Form1_tgSearch_OnChange (Sender: string);
var
iRow ,c: integer;
q, iCol: integer;
begin
c := Form1.tgSearch.RowCount - 1;
q := Form1.tgSearch.Columns.Count-1;
for iRow := 0 to c do
if Form1.tgSearch.Cells[2,iRow] = 'Yes' then
for iCol := 0 to q do Form1.tgSearch.Cell[iCol,iRow].TextColor := $00959595;
//Coloring tgrid WHOLE row TEXT according to combobox Repeat Every cbDetailsRepeat...
for iRow := 0 to c do
if Form1.tgSearch.Cells[3,iRow] = '3 Months' then
for iCol := 0 to q do Form1.tgSearch.Cell[iCol,iRow].TextColor := clGreen;
//Coloring tgrid WHOLE row TEXT according to combobox Month cbDetailsMonth
for iRow := 0 to c do
if Form1.tgSearch.Cells[4,iRow] = 'May' then
for iCol := 0 to q do Form1.tgSearch.Cell[iCol,iRow].TextColor := clPurple;
//Coloring tgrid WHOLE row TEXT according to combobox Day cbDetailsDay
for iRow := 0 to c do
if Form1.tgSearch.Cells[5,iRow] = 'Sunday' then
for iCol := 0 to q do Form1.tgSearch.Cell[iCol,iRow].TextColor := clRed;
end;
Adam
God... please help me become the person my dog thinks I am.