Rogue Wave banner
Previous fileTop of DocumentContentsIndex pageNext file
Stingray Foundation Library User's Guide
Rogue Wave web site:  Home Page  |  Main Documentation Page

9.6 Print Jobs

The CPrintJob class encapsulates the task of sending a document to a printer. A print job takes a printable object and a document and coordinates the task of printing to the document. When a print job is started, it uses the IPrintable interface implemented by the printable object to print pages to the document.

The CPrintJob class uses the IPrintable interface and CPrintDoc classes. At the beginning of a job, CPrintJob calls the StartDoc() function on the CPrintDoc object and is returned an integer value that identifies the job on that printer. Once CPrintJob has started a job on the printer by calling StartDoc(), it invokes the virtual OnPrintDocument() method, which iterates over the pages contained by the printable object and prints them. The CPrintJob class also implements functions for controlling the print job such as Cancel(), Pause(), Resume(), Restart(), Delete() and SetPriority().



Previous fileTop of DocumentContentsNo linkNext file

Copyright © Rogue Wave Software, Inc. All Rights Reserved.

The Rogue Wave name and logo, and Stingray, are registered trademarks of Rogue Wave Software. All other trademarks are the property of their respective owners.
Provide feedback to Rogue Wave about its documentation.