www.gusucode.com > VC++无打印机实现打印预览源码程序 > VC++无打印机实现打印预览源码程序\code\NoPrtPreviewDoc.cpp
// NoPrtPreviewDoc.cpp : implementation of the CNoPrtPreviewDoc class // Download by http://www.NewXing.com #include "stdafx.h" #include "NoPrtPreview.h" #include "NoPrtPreviewDoc.h" #ifdef _DEBUG #define new DEBUG_NEW #undef THIS_FILE static char THIS_FILE[] = __FILE__; #endif ///////////////////////////////////////////////////////////////////////////// // CNoPrtPreviewDoc IMPLEMENT_DYNCREATE(CNoPrtPreviewDoc, CDocument) BEGIN_MESSAGE_MAP(CNoPrtPreviewDoc, CDocument) //{{AFX_MSG_MAP(CNoPrtPreviewDoc) // NOTE - the ClassWizard will add and remove mapping macros here. // DO NOT EDIT what you see in these blocks of generated code! //}}AFX_MSG_MAP END_MESSAGE_MAP() ///////////////////////////////////////////////////////////////////////////// // CNoPrtPreviewDoc construction/destruction CNoPrtPreviewDoc::CNoPrtPreviewDoc() { // TODO: add one-time construction code here } CNoPrtPreviewDoc::~CNoPrtPreviewDoc() { } BOOL CNoPrtPreviewDoc::OnNewDocument() { if (!CDocument::OnNewDocument()) return FALSE; // TODO: add reinitialization code here // (SDI documents will reuse this document) return TRUE; } ///////////////////////////////////////////////////////////////////////////// // CNoPrtPreviewDoc serialization void CNoPrtPreviewDoc::Serialize(CArchive& ar) { if (ar.IsStoring()) { // TODO: add storing code here } else { // TODO: add loading code here } } ///////////////////////////////////////////////////////////////////////////// // CNoPrtPreviewDoc diagnostics #ifdef _DEBUG void CNoPrtPreviewDoc::AssertValid() const { CDocument::AssertValid(); } void CNoPrtPreviewDoc::Dump(CDumpContext& dc) const { CDocument::Dump(dc); } #endif //_DEBUG ///////////////////////////////////////////////////////////////////////////// // CNoPrtPreviewDoc commands