#pragma once
|
#import "c:/Program Files/Common Files/system/ado/msadox.dll"
|
#import "c:/Program Files/Common Files/system/ado/msado15.dll" no_namespace rename("EOF","adoEOF")rename("BOF","adoBOF")
|
|
/*
|
* Access Êý¾Ý¿â½Ó¿Ú³ÌÐò
|
*
|
*
|
*
|
*
|
*/
|
|
int CreateMdb(CString MdbPathName);
|
int OpenMdb(CString MdbPathFileName,_ConnectionPtr & pConnectionPtr);
|
int CloseMdb(_ConnectionPtr & pConnection);
|
int RunSql1( _ConnectionPtr pConnection,CString SqlStr1);//ÔËÐÐûÓзµ»ØÖµµÄSQLÓï¾ä
|
int RunSql2( _ConnectionPtr pConnection,CString SqlStr1,_RecordsetPtr & pRecordsetPtr);//ÔËÐÐÓзµ»ØÖµµÄSQLÓï¾ä
|
|
class MyDataBase
|
{
|
public:
|
CString MdbPathName;
|
CString LastMdbPathName;
|
_ConnectionPtr m_ConnectionPtr;
|
_RecordsetPtr m_RecordsetPtr;
|
int IsOpened;
|
public:
|
MyDataBase();
|
|
~MyDataBase();
|
private:
|
protected:
|
public:
|
int CreateMdb();
|
|
//´´½¨Êý¾Ý¿â±íºÍ×ֶΡ£
|
int CreateMdbStruct();
|
int AddToMdb(int channel,CString SN);
|
int CheckMdb1(CString SerialNo);
|
int AddToOutPutDataBase(int Index,CString ProductCode,CString ProductType, CString ProductDesc,int ColorNo,int Quality,int PowerNo,int ProductLineNo);
|
};
|