testDlg.h
资源名称:wordauto.zip [点击查看]
上传用户:fda_625
上传日期:2007-01-02
资源大小:32k
文件大小:2k
源码类别:
文件操作
开发平台:
Visual C++
- // testDlg.h : header file
- //
- #if !defined(AFX_TESTDLG_H__F45A8327_C1E9_11D2_A0C4_0080C7F3B56B__INCLUDED_)
- #define AFX_TESTDLG_H__F45A8327_C1E9_11D2_A0C4_0080C7F3B56B__INCLUDED_
- #if _MSC_VER > 1000
- #pragma once
- #endif // _MSC_VER > 1000
- #include "WordEventSink.h"
- /////////////////////////////////////////////////////////////////////////////
- // CTestDlg dialog
- class CTestDlg : public CDialog
- {
- // Construction
- public:
- CTestDlg(CWnd* pParent = NULL); // standard constructor
- void OnDocClose();
- // Dialog Data
- //{{AFX_DATA(CTestDlg)
- enum { IDD = IDD_TEST_DIALOG };
- // NOTE: the ClassWizard will add data members here
- //}}AFX_DATA
- // ClassWizard generated virtual function overrides
- //{{AFX_VIRTUAL(CTestDlg)
- protected:
- virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
- //}}AFX_VIRTUAL
- // Implementation
- protected:
- HICON m_hIcon;
- // Generated message map functions
- //{{AFX_MSG(CTestDlg)
- virtual BOOL OnInitDialog();
- afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
- afx_msg void OnPaint();
- afx_msg HCURSOR OnQueryDragIcon();
- virtual void OnOK();
- virtual void OnCancel();
- //}}AFX_MSG
- DECLARE_MESSAGE_MAP()
- private:
- void DumpComError(const _com_error& e) const;
- void DumpOleError(const COleException& e) const;
- void DumpDispatchError(const COleDispatchException& e) const;
- BOOL GetPageCount(DWORD& PageCount);
- Word::_ApplicationPtr m_pWord;
- CWordEventSink m_WordEventSink;
- Word::_DocumentPtr m_pDoc;
- };
- //{{AFX_INSERT_LOCATION}}
- // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
- #endif // !defined(AFX_TESTDLG_H__F45A8327_C1E9_11D2_A0C4_0080C7F3B56B__INCLUDED_)