ResultView.h
资源名称:ISQL_src.zip [点击查看]
上传用户:jsxglz
上传日期:2007-01-03
资源大小:117k
文件大小:3k
源码类别:
SQL Server
开发平台:
Visual C++
- //{{AFX_INCLUDES()
- #include "msflexgrid.h"
- //}}AFX_INCLUDES
- #if !defined(AFX_RESULTVIEW_H__96F0E255_A409_11D1_B9D3_204C4F4F5020__INCLUDED_)
- #define AFX_RESULTVIEW_H__96F0E255_A409_11D1_B9D3_204C4F4F5020__INCLUDED_
- #if _MSC_VER >= 1000
- #pragma once
- #endif // _MSC_VER >= 1000
- // ResultView.h : header file
- //
- /////////////////////////////////////////////////////////////////////////////
- // CResultView form view
- #ifndef __AFXEXT_H__
- #include <afxext.h>
- #endif
- #include "InteractiveSQLDoc.h"
- class CResultView : public CRichEditView
- {
- protected:
- CResultView(); // protected constructor used by dynamic creation
- DECLARE_DYNCREATE(CResultView)
- public:
- CMSFlexGrid* m_pGridCtrl;
- CString m_strObjName;
- // Attributes
- public:
- CInteractiveSQLDoc* GetDocument();
- // Operations
- public:
- void SetWrapNone();
- void SetWrapToWindow();
- // Overrides
- // ClassWizard generated virtual function overrides
- //{{AFX_VIRTUAL(CResultView)
- public:
- virtual void OnInitialUpdate();
- virtual BOOL PreTranslateMessage(MSG* pMsg);
- protected:
- virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
- //}}AFX_VIRTUAL
- // Implementation
- protected:
- virtual ~CResultView();
- virtual HMENU GetContextMenu(WORD wSelType, LPOLEOBJECT lpOleObj, CHARRANGE* lpChrg);
- #ifdef _DEBUG
- virtual void AssertValid() const;
- virtual void Dump(CDumpContext& dc) const;
- #endif
- // Generated message map functions
- //{{AFX_MSG(CResultView)
- afx_msg void OnSize(UINT nType, int cx, int cy);
- afx_msg void OnEditCopy();
- afx_msg void OnUpdateEditCopy(CCmdUI* pCmdUI);
- afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
- afx_msg void OnUpdateFileNew(CCmdUI* pCmdUI);
- afx_msg void OnUpdateFileOpen(CCmdUI* pCmdUI);
- afx_msg void OnUpdateFileSave(CCmdUI* pCmdUI);
- afx_msg void OnUpdateFileSaveAs(CCmdUI* pCmdUI);
- afx_msg void OnFilePrint();
- afx_msg void OnFileSaveAs();
- afx_msg int OnMouseActivate(CWnd* pDesktopWnd, UINT nHitTest, UINT message);
- afx_msg void OnUpdateFilePrint(CCmdUI* pCmdUI);
- afx_msg void OnViewWrapWord();
- afx_msg void OnUpdateViewWrapWord(CCmdUI* pCmdUI);
- afx_msg void OnUpdateEditPaste(CCmdUI* pCmdUI);
- afx_msg void OnSetFocus(CWnd* pOldWnd);
- afx_msg void OnGridSaveSelection();
- afx_msg void OnEditSelectAll();
- afx_msg void OnUpdateEditSelectAll(CCmdUI* pCmdUI);
- //}}AFX_MSG
- DECLARE_MESSAGE_MAP()
- private:
- void CopyGridData();
- BOOL ExportResults(const bool& bSaveSelection = false);
- BOOL ExportToFile(CStdioFile* pFile, LPCTSTR lpszDelimiter, const BOOL& bColumnNames,
- const bool& bSaveSelection = false);
- void InvokeGridMenu();
- CFont m_font;
- };
- #ifndef _DEBUG // debug version in SQLView.cpp
- inline CInteractiveSQLDoc* CResultView::GetDocument()
- { return (CInteractiveSQLDoc*)m_pDocument; }
- #endif
- /////////////////////////////////////////////////////////////////////////////
- //{{AFX_INSERT_LOCATION}}
- // Microsoft Developer Studio will insert additional declarations immediately before the previous line.
- #endif // !defined(AFX_RESULTVIEW_H__96F0E255_A409_11D1_B9D3_204C4F4F5020__INCLUDED_)