Set New Page property on GroupHeader

edited 11:03AM in FastReport VCL 5
Can someone help me how to set new page on or off on pagebreak condition? It is not turning on or off when I execute the code.

Thanks

procedure TFrmRptMnuFastR.frxReport_budactBeforePrint(
Sender: TfrxReportComponent);
var memo : tfrxGroupHeader;
component : TfrxComponent;
begin

case CmBxSortBy.ItemIndex of
0 : begin
component := frxreport_es_k_9.FindObject('GroupHeader1');
memo := component as TfrxGroupheader;
memo.Condition := 'frxDBDataset_budact."PLINE"';
if pagebreak then
memo.StartNewPage := true
else
memo.StartNewPage := false;
end;
1 : begin
component := frxreport_es_k_9.FindObject('GroupHeader1');
memo := component as TfrxGroupheader;
memo.Condition := 'frxDBDataset_budact."Act"';
if pagebreak then
memo.StartNewPage := true
else
memo.StartNewPage := false;
end;
end; // case (CmBxSortBy.ItemIndex)

end;

Comments

  • gpigpi
    edited March 2017
    Set TfrxGroupHeader properties and change dataset sort order before preparing of report

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.