| Início » Artigos » Delphi |
Deixar o DBGrid zebrado
Pessoal boa tarde, hoje vou deixar mais outra dica interessante que é deixar o dbgrid zebrado. Segue cógigo que deve ser colocado no evento OnDrawColumnCell.
if not odd(ClientDataSet.RecNo) then
if not (gdSelected in State) then
begin
dbgridCFOP.Canvas.Brush.Color := clInfoBk;
dbgridCFOP.Canvas.FillRect(Rect);
dbgridCFOP.DefaultDrawDataCell(rect,Column.Field,state);
end;
Até mais....
| |
| Visualizações: 659 | |
| Total de comentários: 0 | |
