📄 courseset.cpp
字号:
// CourseSet.cpp : implementation file
//
#include "stdafx.h"
#include "学生成绩管理系统.h"
#include "CourseSet.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CCourseSet
IMPLEMENT_DYNAMIC(CCourseSet, CDaoRecordset)
CCourseSet::CCourseSet(CDaoDatabase* pdb)
: CDaoRecordset(pdb)
{
//{{AFX_FIELD_INIT(CCourseSet)
m_column1 = _T("");
m_column2 = _T("");
m_column3 = 0;
m_column4 = _T("");
m_nFields = 4;
//}}AFX_FIELD_INIT
m_nDefaultType = dbOpenDynaset;
}
CString CCourseSet::GetDefaultDBName()
{
CString sDir;
TCHAR exepath[MAX_PATH];
::GetModuleFileName(NULL,exepath,MAX_PATH);
sDir=exepath;
sDir=sDir.Left(sDir.GetLength()-20);
sDir+="学生成绩管理系统.mdb";
return sDir;
}
CString CCourseSet::GetDefaultSQL()
{
return _T("[课程]");
}
void CCourseSet::DoFieldExchange(CDaoFieldExchange* pFX)
{
//{{AFX_FIELD_MAP(CCourseSet)
pFX->SetFieldType(CDaoFieldExchange::outputColumn);
DFX_Text(pFX, _T("[课程号]"), m_column1);
DFX_Text(pFX, _T("[课程名]"), m_column2);
DFX_Short(pFX, _T("[学分]"), m_column3);
DFX_Text(pFX, _T("[学期]"), m_column4);
//}}AFX_FIELD_MAP
}
/////////////////////////////////////////////////////////////////////////////
// CCourseSet diagnostics
#ifdef _DEBUG
void CCourseSet::AssertValid() const
{
CDaoRecordset::AssertValid();
}
void CCourseSet::Dump(CDumpContext& dc) const
{
CDaoRecordset::Dump(dc);
}
#endif //_DEBUG
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -