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

📄 enroldoc.cpp

📁 VC6数据库开发指南
💻 CPP
字号:
// EnrolDoc.cpp : implementation of the CStdInfoDoc class
//

#include "Stdafx.h"
#include "Stdinfo.h"
#include "SectionSet.h"
#include "CourseSet.h"
#include "StdinfoDoc.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CUpdateHint

IMPLEMENT_DYNAMIC(CUpdateHint, CObject)

CUpdateHint::CUpdateHint()
{
}


/////////////////////////////////////////////////////////////////////////////
// CStdInfoDoc

IMPLEMENT_DYNCREATE(CStdInfoDoc, CDocument)

BEGIN_MESSAGE_MAP(CStdInfoDoc, CDocument)
	//{{AFX_MSG_MAP(CStdInfoDoc)
		// 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()

/////////////////////////////////////////////////////////////////////////////
// CStdInfoDoc construction/destruction

CStdInfoDoc::CStdInfoDoc()
{
	// TODO: add one-time construction code here

}

CStdInfoDoc::~CStdInfoDoc()
{
}

BOOL CStdInfoDoc::OnNewDocument()
{
	if (!CDocument::OnNewDocument())
		return FALSE;

	// TODO: add reinitialization code here
	// (SDI documents will reuse this document)

	return TRUE;
}

/////////////////////////////////////////////////////////////////////////////
// CStdInfoDoc database support

CDatabase* CStdInfoDoc::GetDatabase()
{
	TRY
	{
		if (!m_database.IsOpen())
			m_database.Open("Student Registration;");
	}
	CATCH(CDBException, e)
	{
		AfxMessageBox(e->m_strError);
	}
	END_CATCH
	return &m_database;
}

/////////////////////////////////////////////////////////////////////////////
// CStdInfoDoc diagnostics

#ifdef _DEBUG
void CStdInfoDoc::AssertValid() const
{
	CDocument::AssertValid();
}

void CStdInfoDoc::Dump(CDumpContext& dc) const
{
	CDocument::Dump(dc);
}
#endif //_DEBUG

/////////////////////////////////////////////////////////////////////////////
// CStdInfoDoc commands

⌨️ 快捷键说明

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