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

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

← →
Pos Eleptant (c)   (2008-02-28 14:01) [0]

Подскажите код, как отразить Bitmap в ячейке Grid

OnDBGridDrawColumnCell не работает

  if Column.FieldName="UPD_STATUS" then
  if Column.Field.AsInteger = 0 then
  begin
showmessage("2");
    dbgrid.canvas.Draw(Rect.Left, Rect.Top, imgFlagEdit.Picture.Bitmap);
    dbgrid.
  end;


← →
Desdechado ©   (2008-02-28 15:03) [1]

procedure TframeTree.ObjGridDrawColumnCell( Sender: TObject; const Rect: TRect;
                                           DataCol: Integer; Column: TColumn;
                                           State: TGridDrawState );
var
 nImg: Integer;
begin
 if not TDBGrid(Sender).DataSource.DataSet.IsEmpty then begin
   if( Column.FieldName = "CLASS_ID" ) then begin
     ObjGrid.Canvas.FillRect( Rect );
     nImg := Column.Field.AsInteger;
     DataModule.ClassImg.Draw( ObjGrid.Canvas, Rect.Left + 2, Rect.Top, nImg );
   end
   else
     ObjGrid.DefaultDrawColumnCell( Rect, DataCol, Column, State );
 end;
end;



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

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



Память: 0.44 MB
Время: 0.01 c
2-1205763221
Berkoot
2008-03-17 17:13
2008.04.13
Надстрочный индекс в Delphi


2-1205518291
La-la-Land
2008-03-14 21:11
2008.04.13
Интернет и файлы


15-1204280231
Palladin
2008-02-29 13:17
2008.04.13
Вот вам и неограниченность объектов ядра в совр. Windows


15-1204078326
Fon
2008-02-27 05:12
2008.04.13
Google Summer of Code 2008


15-1204114557
Джо
2008-02-27 15:15
2008.04.13
Посоветуйте хостинг в Украине




   Наверх