FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour FastReport GroupHeader
Posts: 6983
Joined: Fri Oct 07, 2005 07:07 PM
FastReport GroupHeader
Posted: Mon Jan 11, 2010 03:49 AM
To switch on/off GroupHeader and StartNewPage from within your Fivewin application you can pass 2 variables and then define the OnBeforePrint condition of the GroupHeader:
Fivewin:
Code (fw): Select all Collapse
if lGruppenKopf = .t.
oFr:AddVariable("Einstellungen", "Gruppenkopf", "'JA'")
else

oFr:AddVariable("Einstellungen", "Gruppenkopf", "'NEIN'")
endif

if lVorschub  = .t.
oFr:AddVariable("Einstellungen", "NeueSeite", "'JA'")
else
oFr:AddVariable("Einstellungen", "NeueSeite", "'NEIN'")
endif


PascalScript in Fast Report
Code (fw): Select all Collapse
procedure F_GroupHeader1(Sender: TfrxComponent);

begin
   GroupHeader1.Visible := Trim(<Gruppenkopf>) = 'JA'    ;
   GroupHeader1.StartNewPage := Trim(<NeueSeite>) = 'JA'    ;               
end;


Best regards,
Otto
Posts: 6983
Joined: Fri Oct 07, 2005 07:07 PM
Re: FastReport GroupHeader
Posted: Mon Jan 11, 2010 04:00 AM
You can also pass a boolean-variable:

Code (fw): Select all Collapse
Fivewin:
oFr:AddVariable("Einstellungen", "TestLogischeVariable", .T. )
FastReport:
GroupHeader1.Visible :=   <TestLogischeVariable>   ;

Best regards,
Otto

Continue the discussion