⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 数据库作业view.h

📁 用vc实现的连接sql数据库程序
💻 H
字号:
// 数据库作业View.h : interface of the CMyView class
//
/////////////////////////////////////////////////////////////////////////////

#if !defined(AFX_VIEW_H__21658EFD_4CB0_40DD_B07C_804D8CE1FE74__INCLUDED_)
#define AFX_VIEW_H__21658EFD_4CB0_40DD_B07C_804D8CE1FE74__INCLUDED_
#include <afxtempl.h>
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

class CMySet;
#include "数据库作业Doc.h"

class CMyView : public CRecordView
{
protected: // create from serialization only
	CMyView();
	DECLARE_DYNCREATE(CMyView)

public:
	//{{AFX_DATA(CMyView)
	enum { IDD = IDD_MY_FORM };
	CListCtrl	m_ResultList;
	CMySet * m_pSet;
	CString	m_strSQL;
	//}}AFX_DATA

// Attributes
public:
	CMyDoc* GetDocument();

// Operations
public:

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CMyView)
	public:
	virtual CRecordset* OnGetRecordset();
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	virtual void OnInitialUpdate(); // called first time after construct
	virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
	virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
	//}}AFX_VIRTUAL

// Implementation
public:
	void ShowDate();
	virtual ~CMyView();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:
// Generated message map functions
protected:
	BOOL m_bUICanEdit;
	BOOL m_bUICanDel;
	int m_nTableFlags;
	short nColums;
	//{{AFX_MSG(CMyView)
	afx_msg void OnGetSQL();
	afx_msg void OnColumnclickListReport(NMHDR* pNMHDR, LRESULT* pResult);
	afx_msg void OnQueryStudent();
	afx_msg void OnQueryClssInfo();
	afx_msg void OnQuerySCInfo();
	afx_msg void OnInsertStudent();
	afx_msg void OnInsertClass();
	afx_msg void OnInsertSC();
	afx_msg void OnPopmenuAdd();
	afx_msg void OnPopmenuDel();
	afx_msg void OnPopmenuEdit();
	afx_msg void OnRclickListReport(NMHDR* pNMHDR, LRESULT* pResult);
	afx_msg void OnUpdatePopmenuDel(CCmdUI* pCmdUI);
	afx_msg void OnUpdatePopmenuEdit(CCmdUI* pCmdUI);
	afx_msg void OnDeleteSQLText();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
private:
	void ExecuteSQL(CString strSQL);
};

#ifndef _DEBUG  // debug version in 数据库作业View.cpp
inline CMyDoc* CMyView::GetDocument()
   { return (CMyDoc*)m_pDocument; }
#endif

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_VIEW_H__21658EFD_4CB0_40DD_B07C_804D8CE1FE74__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -