Hi,
I have this Grid that shows the PC parts. But instead of displaying the Items, it displayed "(Memo)".
I've read many threads it says it can be done like this:
procedure TForm1.DBGrid1DrawDataCell(Sender: TObject; const Rect: TRect;
Field: TField; State: TGridDrawState);
var
S: String;
begin
if Field.DataType = ftMemo then
begin
S := Field.AsString;
DBGrid1.Canvas.Pen.Color := clWindow;
DBGrid1.Canvas.Brush.Color := clWindow;
DBGrid1.Canvas.Rectangle(Rect);
DBGrid1.Canvas.TextOut(Rect.Left, Rect.Top, S);
end;
end;
But the UniDBGrid1.Canvas shows error. May i know your suggestions. Thanks