資源簡介
實現數據庫的調用,調用數據庫,實現數據的隨機提取。

代碼片段和文件信息
//?kekeSet.cpp?:?implementation?of?the?CKekeSet?class
//
#include?“stdafx.h“
#include?“kekeSet.h“
#ifdef?_DEBUG
#define?new?DEBUG_NEW
#undef?THIS_FILE
static?char?THIS_FILE[]?=?__FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
//?CKekeSet?implementation
IMPLEMENT_DYNAMIC(CKekeSet?CRecordset)
CKekeSet::CKekeSet(CDatabase*?pdb)
:?CRecordset(pdb)
{
//{{AFX_FIELD_INIT(CKekeSet)
m_type?=?_T(““);
m_a1?=?0;
m_a2?=?0;
m_a3?=?0;
m_a4?=?0;
m_a5?=?0;
m_nFields?=?6;
//}}AFX_FIELD_INIT
m_nDefaultType?=?snapshot;
}
CString?CKekeSet::GetDefaultConnect()
{
return?_T(“ODBC;DSN=MS?Access?Database“);
}
CString?CKekeSet::GetDefaultSQL()
{
return?_T(“[table1]“);
}
void?CKekeSet::DoFieldExchange(CFieldExchange*?pFX)
{
//{{AFX_FIELD_MAP(CKekeSet)
pFX->SetFieldType(CFieldExchange::outputColumn);
RFX_Text(pFX?_T(“[type]“)?m_type);
RFX_Long(pFX?_T(“[a1]“)?m_a1);
RFX_Long(pFX?_T(“[a2]“)?m_a2);
RFX_Long(pFX?_T(“[a3]“)?m_a3);
RFX_Long(pFX?_T(“[a4]“)?m_a4);
RFX_Long(pFX?_T(“[a5]“)?m_a5);
//}}AFX_FIELD_MAP
}
/////////////////////////////////////////////////////////////////////////////
//?CKekeSet?diagnostics
#ifdef?_DEBUG
void?CKekeSet::AssertValid()?const
{
CRecordset::AssertValid();
}
void?CKekeSet::Dump(CDumpContext&?dc)?const
{
CRecordset::Dump(dc);
}
#endif?//_DEBUG
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件?????143360??2010-12-20?21:01??p1\db1.mdb
?????文件???????1425??2006-07-08?18:59??p1\kekeSet.cpp
?????文件???????1300??2006-07-08?18:48??p1\kekeSet.h
?????文件??????????0??2010-12-14?20:34??p1\odbset.h
?????文件?????111108??2010-12-22?12:52??p1\p1.aps
?????文件???????2254??2010-12-22?13:06??p1\p1.clw
?????文件???????2029??2006-07-08?19:39??p1\p1.cpp
?????文件???????5029??2010-05-04?21:26??p1\p1.dsp
?????文件????????527??2006-07-08?18:54??p1\p1.dsw
?????文件???????1280??2006-07-08?18:54??p1\p1.h
?????文件??????66560??2010-12-22?13:06??p1\p1.ncb
?????文件??????51712??2010-12-22?13:06??p1\p1.opt
?????文件???????1557??2010-12-22?12:52??p1\p1.plg
?????文件???????8103??2010-12-22?12:52??p1\p1.rc
?????文件????????869??2010-11-14?23:13??p1\p1.sln
????..A..H.??????8192??2010-12-04?23:26??p1\p1.suo
?????文件???????8457??2010-11-14?23:13??p1\p1.vcproj
?????文件???????1427??2010-12-04?23:26??p1\p1.vcproj.DELL-7EE5D7AD7B.Owner.user
?????文件??????14602??2010-12-20?21:00??p1\p1Dlg.cpp
?????文件???????2085??2010-12-14?19:50??p1\p1Dlg.h
?????文件???????3507??2006-07-08?18:54??p1\ReadMe.txt
?????文件???????6058??2010-05-04?21:16??p1\res\bitmap1.bmp
?????文件???????5438??2010-05-04?21:16??p1\res\bitmap10.bmp
?????文件???????5438??2010-05-04?21:16??p1\res\bitmap11.bmp
?????文件???????6118??2010-05-04?21:16??p1\res\bitmap12.bmp
?????文件???????6118??2010-05-04?21:16??p1\res\bitmap2.bmp
?????文件???????6058??2010-05-04?21:16??p1\res\bitmap3.bmp
?????文件???????5998??2010-05-04?21:16??p1\res\bitmap4.bmp
?????文件???????6058??2010-05-04?21:16??p1\res\bitmap5.bmp
?????文件???????5938??2010-05-04?21:16??p1\res\bitmap6.bmp
............此處省略14個文件信息
評論
共有 條評論