DBGrid com Imagens
:lol: Pessoal gostaria de saber se algum pode me ajudar preciso de um componente estilo DBGrid ou algo que possa apresentar imagens dentro das células... o interesse é para fazer uma aplicação com semáforos....
Caso alguém possa me ajudar agradeço.... :lol:
Caso alguém possa me ajudar agradeço.... :lol:
Judafox
Curtidas 0
Respostas
Motta
09/09/2003
Existem uns pagos na web , a CD teve artigo sobre um destes.
Existem uns free tb.
Vc pode usar tb um Tdbctrlgrid
Existem uns free tb.
Vc pode usar tb um Tdbctrlgrid
GOSTEI 0
Judafox
09/09/2003
acabei de achar um componete muito bom sobre o assunto...
vo deixar o link caso alguem queira...
link: http://www.geocities.com/SiliconValley/Horizon/6414/delphi/arqs/dbgrdpls.zip
vo deixar o link caso alguem queira...
link: http://www.geocities.com/SiliconValley/Horizon/6414/delphi/arqs/dbgrdpls.zip
GOSTEI 0
Paulo Almeida
09/09/2003
Se a sua tabela tiver um campo, blob(Grafhic), selecione o DBGrid e no evento Draw ColumnCell (code Editor digite:
procedure T_imapesquisa.DBGrid1DrawColumnCell(Sender: TObject;
const Rect: TRect; DataCol: Integer; Column: TColumn;
State: TGridDrawState);
var
Bitmap:TBitmap;
begin
If Column.Field is TGraphicField then
with DBGrid1.Canvas do Begin
FillRect(Rect);
Bitmap :=TBitmap.Create;
try
Bitmap.Assign(Column.Field);
Draw(Rect.Left,Rect.Top, Bitmap);
finally
Bitmap.Free;
end;
Tenha bom proveito
procedure T_imapesquisa.DBGrid1DrawColumnCell(Sender: TObject;
const Rect: TRect; DataCol: Integer; Column: TColumn;
State: TGridDrawState);
var
Bitmap:TBitmap;
begin
If Column.Field is TGraphicField then
with DBGrid1.Canvas do Begin
FillRect(Rect);
Bitmap :=TBitmap.Create;
try
Bitmap.Assign(Column.Field);
Draw(Rect.Left,Rect.Top, Bitmap);
finally
Bitmap.Free;
end;
Tenha bom proveito
GOSTEI 0
Judafox
09/09/2003
ok Paulo obrigado pela dica....
GOSTEI 0