Kod:
if DBGrid1.DataSource.DataSet.RecNo mod 2 = 0 then // cift sayılı alanların rengi 0,2,4.... Dbgrid1.Canvas.brush.Color := $00AEEBF0 else if DBGrid1.DataSource.DataSet.RecNo mod 2 = 1 then // tek sayılı alanların rengi 1,3,5... Dbgrid1.Canvas.Brush.Color := clWindow; with DBGrid1.Canvas do begin if (gdSelected in State) then // secili alanın renk ve yazı fontu begin Brush.Color := $00E2D032; //secim rengi Font.Color := ClBlack; // yazı rengi Font.Size:=10; // yazı buyukluğu Font.Style := font.Style + [fsBold]; // yazı kalın olsun FillRect(rect); end; end; DBGrid1.DefaultDrawColumnCell(Rect, DataCol, Column, State);
__________________
DbGridde satır boyama
Programlama0 Mesaj
●25 Görüntüleme
- ReadBull.net
- Programlama ve Yazılım
- Programlama
- DbGridde satır boyama