Если значений StrId немного, то вот так (в DrawColumnCell грида):
Код:
if DBGrid1.datasource.dataset.fieldbyname('StrID').AsInteger= 1 then
begin
DBGrid1.Canvas.Brush.Color := clRed;
DBGrid1.Canvas.Font.Color := clYellow;
end
else
begin
DBGrid1.Canvas.Brush.Color := clYelow;
DBGrid1.Canvas.Font.Color := clRed;
end;
DBGrid1.DefaultDrawColumnCell(Rect, DataCol, Column, State);
DefaultDrawing=false у грида не забываем