OnRunDialogs. How does it work?

edited January 2006 in FastReport 3.0
I wrote a report and it has a dialog page to ask for parameters. I need to call this report from a specific place but I don't want to show the dialog page. I mean, I want to control when a dialog page will be showed or not.
I already tryied using the option PrintOptions.ShowDialog := False but it doesn't work as I expected.
I debugged frxEngine and it seems I can avoid showing the dialog page setting the property OnRunDialogs but I don't know how to do it.
Please, could someone explain it to me or if possible, post a example.

Thanks a lot!

Comments

  • gordkgordk St.Catherines On. Canada.
    edited 8:41PM
    where you call the report typically,
    var dgpage: tfrxdialogpage;
    begin
    frxreport1.loadfromfile('path&filename');
    //write code here to find dialog page and set its visible property to false.
    dgpage := frxreport1.findobject('DialogPage1');
    dgpage.visible := false;
    frxreport1.showreport;
    end;
    ;)

Leave a Comment