How to print Fastreport directly without showing a print dialog

I use Fastreport 4. I need to print directly to the printer without showing the Print Dialog. I disabled ShowDialog in the print options, but it continues to show the print dialog. Any help would be greatly appreciated.

+5
source share
3 answers

You must install it after downloading the report.

Report.LoadFromFile('filename');
Report.PrepareReport;
Report.PrintOptions.ShowDialog := False;
Report.Print;
+15
source

If you assigned a fake line to the "OnRunDialogs" event after loading the report below, your dialogs do not open.

frxMyReport.LoadFromFile (FPATH); frxMyReport.OnRunDialogs = "fakeevent";

0
source
Report report = new Report();

report.Load(@"C:\Something.frx");

# ... <rest-of-your-code>

report.PrintSettings.ShowDialog = false;

report.Print();
0

All Articles