Hi all,
I hate QReport...this is the most stupid prog. i have ever seen... OK, now i feel much better....
Is it the way to explain to QReport that it does not have to do the following:
If you create report end preview it, everithing is OK, but when you print it the stupid QReport will create it again ?!!, and you will have bunch of stupiditi on it (if you are using Befor and After print events on Bands). So now you have to use some Variables to determin if the report is printing or previewing etc.
So, one more time... is it possible for QReport to act like any other Windows program and print previewed picture to printer?
------
When you print from the preview, the report is rendered again. The reason is the preview is rendered to a metafile, and the output looks better if it's directly rendered to the printer canvas. You can override this behaviour, when you print a previously saved report, the preview metafile is sent to the printer.
Set the OnGenerateToPrint event of the report's qrprinter object to nil. This will force the report to not render the report a second time.
Example:
procedure Tfrmqr.QuickRep1BeforePrin
begin
QuickRep1.qrprinter.OnGene
end;