Вниз
Скачать: CL | DM;

RxDBGrid1DrawColumnCell   Найти похожие ветки 

← →
Sheva ©   (2002-09-10 12:35) [0]

Есть такой код:

procedure TOpenForm.RxDBGrid1DrawColumnCell(Sender: TObject;
const Rect: TRect; DataCol: Integer; Column: TColumn;
State: TGridDrawState);
var
ARect: TRect;
begin
if gdselected in state then
with RxDBGrid1 do
begin
//if TempContractQuery.FieldByName("SellOrBuy").AsInteger=1
//then
//begin
CopyRect(ARect, Rect);
Canvas.Brush.Color:= clred;
Canvas.Font.Color:= clBlack;
Canvas.FillRect(Rect);
//end;
end;
end;

При этом нужная строка закрашивается в красный цвет.

Вопрос: как вывести текст поверх Rect-а, а то вижу только красную строку.
Спасибо.


← →
Игорь Шевченко ©   (2002-09-10 13:10) [1]

Вставить строку
DefaultDrawColumnCell(Rect,DataCol,Column,State);
после FillRect



← →
Sheva ©   (2002-09-10 13:15) [2]

Огромное спасибо. Все заработало.



Страницы: 1 вся ветка

Скачать: CL | DM;



Память: 0.44 MB
Время: 0.01 c
1-73753
Leviathan
2002-09-07 20:27
2002.09.23
Overoading


1-73693
soware
2002-09-11 05:02
2002.09.23
Запуск программы ДОС


14-73874
MBo
2002-08-25 08:05
2002.09.23
Поздравляю Vad c днем рождения!


14-73876
.nuke
2002-08-29 15:01
2002.09.23
А здесь есть кто из Ульяновска?


1-73726
Starkom
2002-09-11 09:05
2002.09.23
Про цветной Caption TabSheet a




   Наверх