Hola amigos:
Después de andar bastante, he logrado manejar el tema, y agradecido a todo lo que me enseñaron todos desde allí, a continuación listo como lo hago:
Código Delphi
[-]
procedure TFECuentaCasaConque.GrillaDrawColumnCell(Sender: TObject; const Rect: TRect;
DataCol: Integer; Column: TColumn; State: TGridDrawState);
var Num: Integer;
R: TRect;
Conque, Haber: Integer;
begin
if (DataCol = 2) or (DataCol = 5) then
with dmCajaHogar do
begin
if QCuentaCasa.FieldByName('HABER').AsInteger = 0 then
begin
Grilla.Canvas.Brush.Color:= $00F3E8FF;
Grilla.Canvas.Font.Color:= clRed;
Grilla.DefaultDrawColumnCell(Rect, DataCol, Column, State);
end;
endGrilla.Canvas.Brush.Color:= clLimMed1;
4:
else
if (DataCol in [3,6]) then
with dmCajaHogar do
begin
Num:=TStringGrid(Grilla).Row;
R:=TStringGrid(Grilla).CellRect(DataCol,Num);
with Grilla do
begin
Conque:= QCuentaCasa.FieldByName('CONQUE').AsInteger;
if not(gdFocused in State) then
case Conque of
1: Grilla.Canvas.Brush.Color:= clVerCla1;
2: Grilla.Canvas.Brush.Color:= clCelMed1;
3:
end
else
if gdFocused in State then
case dmCajaHogar.QCajaHogarCON.AsInteger of
1: Grilla.Columns[3].color:= clVerCla2;
2: Grilla.Columns[3].color:= clCelMed2;
end;
Grilla.DefaultDrawColumnCell(Rect, DataCol, Column, State);
end;
end;
end;
Un abrazo y saludos a todos.
Lisandro