![]() |
PrintPreview does not work! |
Post Reply ![]() |
Author | |
spike ![]() Groupie ![]() Joined: 13 May 2003 Location: United States Status: Offline Points: 48 |
![]() ![]() ![]() ![]() ![]() Posted: 24 November 2004 at 3:58pm |
I am trying to get PrintPreview to work using the XTPPrintPreview class in my project.
void CSchedulerFormView::OnToolBarButtonClick(UINT nID) if ( !DoPrintPreview( XTP_IDD_PREVIEW_TOOLBAR, this, BOOL CSchedulerFormView::OnPreparePrinting(CPrintInfo* pInfo) void CSchedulerFormView::OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo) void CSchedulerFormView::OnEndPrinting(CDC* pDC, CPrintInfo* pInfo) I have that code and it gets called with no problems, but the print preview window is empty. Which is the same thing that happens in the PrintPreview sample. The only difference is I in the PrintPreview sample you use CEditView (which only shows the first character in preview mode) and I am using a CFormView. On my preview window I get an empty white preview window. Can someone who has gotten this to work show me what I am doing wrong or let me know if it doesnt work?
Thanks Craig |
|
![]() |
|
Oleg ![]() Senior Member ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
CFormView hasn't preview output. You can easy check it: Create simple MFC application with CFormView as view class. Print Preview will show empty window. |
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
spike ![]() Groupie ![]() Joined: 13 May 2003 Location: United States Status: Offline Points: 48 |
![]() ![]() ![]() ![]() ![]() |
Oleg, Even so, the print preview sample does not work. Try for yourself. Type something in the document and preview it. On any machine I have tried it on I only see the first character |
|
![]() |
|
Oleg ![]() Senior Member ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
It is bug of MFC 4.2 with manifest used. try to comment in rc file: IDR_MANIFEST 24 DISCARDABLE "res\\manifest.xml" |
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
Post Reply ![]() |
|
Tweet
|
Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |