Guides & Tutorials (beta)

Printing a Report

by Mike Palmatier Visual C++ Created on 05/03/2008  |  Updated on 08/28/2024 0/5 ( 0 votes )

To print a report all you need to do is derive your current view from CXTPReportView. Then you can use the standard CView print methods to print the report.

class CReportSampleView : public CXTPReportView

The code below shows what your message map might look like for printing functions.

BEGIN_MESSAGE_MAP(CReportSampleView, CXTPReportView)
    // Standard printing commands

    ON_COMMAND(ID_FILE_PRINT, CView::OnFilePrint)
    ON_COMMAND(ID_FILE_PRINT_DIRECT, CView::OnFilePrint)
    ON_COMMAND(ID_FILE_PRINT_PREVIEW, CView::OnFilePrintPreview)
END_MESSAGE_MAP()

User Comments

No comments yet, sign in to comment.

Secure Transactions

Online transactions are secure and protected.


Ssl seal 1
This site is protected by Trustwave's Trusted Commerce program
CompliAssure Secured

Money Back Guarantee

If you are not 100% happy with your purchase within 30 days, you can return it for any reason. Your satisfaction is our priority!


Satisfication Guaranteed

Contact sales@codejock.com for more details.