Hi John

Try putting your code in OnDrawColumnCell() and make sure your DBgrid event
is hooked to the event handler method in the object inspector.

Todd.

----- Original Message ----- 
From: "John" <[EMAIL PROTECTED]>
To: "NZ Borland Developers Group - Delphi List" <[EMAIL PROTECTED]>
Sent: Friday, December 12, 2003 1:50 PM
Subject: [DUG] OnDrawDataCell


> Hi all,
>
> I have this application with a Tdbgrid hooked to an OnDrawDataCell event.
I
> have used this before so in principle not a problem.
>
> However, with this application it does not seem to respond on this
> OnDrawDataCell event. When I put something simple in the event like
> showMessage('test') it seems never been called (see code below).
>
> procedure TForm1.dbgridClientsDrawDataCell(Sender: TObject; const Rect:
> TRect; Field: TField; State: TGridDrawState);
> begin
>   ShowMessage('Test');
> end;
>
> The Tdbgrid object's event is obviously registered in the component's
event
> list.
>
> When I create a little application with just this Tdbgrid object and a
table
> and datasource it works OK. However, when I copy these objects to THE
> application then the event is not called any more.
>
> I'm running D7.
>
> Any ideas?
>
> TIA
> John
>
> _______________________________________________
> Delphi mailing list
> [EMAIL PROTECTED]
> http://ns3.123.co.nz/mailman/listinfo/delphi
>


_______________________________________________
Delphi mailing list
[EMAIL PROTECTED]
http://ns3.123.co.nz/mailman/listinfo/delphi

Reply via email to