change text in memo before print

edited 10:36AM in FastReport 4.0
Delphi XE2.
I have a Memo field in a report named frxReportPermits

I need to change the value of the text in Memo2.

How do I access the Memo2 value in the onbeforeprint ?

If I try frxReportPermits.Memo2.Text this does not work.


Cheers


SteveW

Comments

  • gpigpi
    edited 10:36AM
    Try

    TfrxMemoView(frxReportPermits.FindObject('Memo2')).Memo.Text
  • edited 10:36AM
    procedure TReports.frxReport1BeforePrint(Sender: TfrxReportComponent);
    var
    memo_1 : TfrxMemoView ;
    begin
    memo_1 := frxReport1.FindObject('memo1') as TfrxMemoView;
    memo_1.Text:='mytext';

Leave a Comment