Change leftmargin at runtime

Have you a nice day.

I want change the margin at runtime from my delphi berlin.
I use the fastreport VCL last version.

var
Page: TfrxReportPage;
begin
page := TfrxReportPage(frxMyReport.FindComponent('Page1'));
Page.LeftMargin:=20;
Page.RightMargin:=10;
Page.TopMargin:=10;
Page.BottomMargin:=10;
frxMyReport.ShowReport;
end;

For me doesn't work fine
Thanks a lot

Comments

  • gordkgordk St.Catherines On. Canada.
    edited 7:20PM
    try
    var
    Page: TfrxReportPage;
    Page :=frxMyReport .Pages[1] as TfrxReportPage;
  • gpigpi
    edited 7:20PM
    or
    page := TfrxReportPage(frxMyReport.FindObject('Page1'));
    

Leave a Comment