Solved

QReport @@#!!!! grrrrrr

Posted on 1998-12-23
4
316 Views
Last Modified: 2010-04-04

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?
0
Comment
Question by:rpetruni
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 8

Expert Comment

by:ZifNab
ID: 1352698
What about prepare method.
0
 
LVL 1

Author Comment

by:rpetruni
ID: 1352699
please, be more specific... what prepare method does?
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1352700
sorry, thought it would help, but it doesn't. It's only usefull for preparing the report and then save it to file in QRP file...
0
 

Accepted Solution

by:
AG112297 earned 20 total points
ID: 1352701
from the KB.txt file available at www.qusoft.com
------
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.QuickRep1BeforePrint(Sender: TQuickRep; var PrintReport: boolean);
begin
  QuickRep1.qrprinter.OnGenerateToPrinter := nil;
end;

0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question