Inherited reports in DFM does not respect "Papersize"
I have problem with reports in DFM that are inherited.
Template report (MainRep.pas) is Portrait and have page settings A4 (21x29,7).
I've created two reports that was inherited from template report.
- First report (Rep.pas) is the same as template report (Page setup have Page size A4 and dimensions 21x29,7)
- Second report (Rep_landscape.pas) is landscape (Page setup have Page size A4 and dimensions 29,7x21)
Problem is when i print report, because first report prints on A4 and everything is OK, but when I print second report, it change paper size to "Custom" (not A4) and printer can't print until I go to printer and select that I want to print that page (which is Custom and not A4) on A4 paper.
When I look in DFM files of reports:
object Page1: TfrxReportPage PaperWidth = 210.000000000000000000 PaperHeight = 297.000000000000000000 PaperSize = 9 LeftMargin = 10.000000000000000000 RightMargin = 10.000000000000000000 TopMargin = 10.000000000000000000 BottomMargin = 10.000000000000000000 Frame.Typ =  MirrorMode =  end
inherited Page1: TfrxReportPage end
inherited Page1: TfrxReportPage Orientation = poLandscape PaperWidth = 297.000000000000000000 PaperHeight = 210.000000000000000000 end
I think that second report should have "PaperSize = 9" because it is still A4 page but only landscape or should read paper size from template report.
Solution is that I can explicitly set "PaperSize := 9" before print, but it would be nicer if you can fix that.
I've attached example in which you can see that when you click on "Preview" button, and in preview window on "Page Settings" the page size is "A4", but when you click on "Preview landscape" button, and in preview window on "Page Settings" then page size is "Custom".