C源码分析Kit6012Word格式.docx
- 文档编号:22163699
- 上传时间:2023-02-02
- 格式:DOCX
- 页数:12
- 大小:16.52KB
C源码分析Kit6012Word格式.docx
《C源码分析Kit6012Word格式.docx》由会员分享,可在线阅读,更多相关《C源码分析Kit6012Word格式.docx(12页珍藏版)》请在冰豆网上搜索。
rst.ExecuteSQL(ss);
m_nAiNewlist.DeleteAllItems();
loadlist();
datatotext();
texttowin();
OnExit()
EndDialog(true);
OnUpdate()
enbalewin(true);
enablebutton(false);
khjbxiugai=1;
OnSave()
wintotext();
CStringss,srept;
srept.Format("
selectfromtb_nAiNewClient_nAiNewkhjbwherekhjb_nAiNewjbmc='
edit2);
rst.rstOpen(srept);
if(rst.GetRecordCount()>
0)
MessageBox("
这个级别名称已经存在了"
if(khjbxiugai==1)
{ss.Format("
UPDATEtb_nAiNewClient_nAiNewkhjbsetkhjb_nAiNewjbmc='
khjb_nAiNewzdywl='
khjb_nAiNewbz='
wherekhjb_nAiNewid='
edit2,edit3,edit4,edit1);
else
INSERTINTOtb_nAiNewClient_nAiNewkhjbvalues('
'
)"
edit1,edit2,edit3,edit4);
enbalewin(false);
enablebutton(true);
khjbxiugai=0;
clearall()
m_nAiNewedit1.SetWindowText("
m_nAiNewedit2.SetWindowText("
m_nAiNewedit3.SetWindowText("
m_nAiNewedit4.SetWindowText("
enablebutton(boolbutn)
toolbar.EnableButton(ID_nAiNewADD,butn);
toolbar.EnableButton(ID_nAiNewUPDATE,butn);
toolbar.EnableButton(ID_nAiNewDELETE,butn);
toolbar.EnableButton(ID_nAiNewSAVE,!
butn);
toolbar.EnableButton(ID_nAiNewCANCEL,!
enbalewin(boolwi)
m_nAiNewedit1.EnableWindow(wi);
m_nAiNewedit2.EnableWindow(wi);
m_nAiNewedit3.EnableWindow(wi);
m_nAiNewedit4.EnableWindow(wi);
texttowin()
m_nAiNewedit1.SetWindowText(edit1);
m_nAiNewedit2.SetWindowText(edit2);
m_nAiNewedit3.SetWindowText(edit3);
m_nAiNewedit4.SetWindowText(edit4);
wintotext()
m_nAiNewedit1.GetWindowText(edit1);
m_nAiNewedit2.GetWindowText(edit2);
m_nAiNewedit3.GetWindowText(edit3);
m_nAiNewedit4.GetWindowText(edit4);
datatotext()
edit1=m_nAiNewlist.GetItemText(khjbclnum,0);
edit2=m_nAiNewlist.GetItemText(khjbclnum,1);
edit3=m_nAiNewlist.GetItemText(khjbclnum,2);
edit4=m_nAiNewlist.GetItemText(khjbclnum,3);
loadlist()
rst.rstOpen("
selectfromtb_nAiNewClient_nAiNewkhjb"
intrecordcount=rst.GetRecordCount();
intii;
for(ii=1;
ii<
=recordcount;
ii++)
m_nAiNewlist.InsertItem(ii-1,"
m_nAiNewlist.SetItemText(ii-1,0,rst.GetFieldValue("
khjb_nAiNewid"
));
m_nAiNewlist.SetItemText(ii-1,1,rst.GetFieldValue("
khjb_nAiNewjbmc"
m_nAiNewlist.SetItemText(ii-1,2,rst.GetFieldValue("
khjb_nAiNewzdywl"
m_nAiNewlist.SetItemText(ii-1,3,rst.GetFieldValue("
khjb_nAiNewbz"
rst.Move(ii);
rst.close();
autonum()
adorst3;
rst3.rstOpen("
if(rst3.GetRecordCount()==0)
KJB001"
m_nAiNewedit1.EnableWindow(false);
rst3.MoveLast();
CStringmm=rst3.GetFieldValue("
intxuhao=atoi(mm.Right(3));
xuhao+=1;
mm.Format("
KJB%03d"
xuhao);
m_nAiNewedit1.SetWindowText(mm);
rst3.close();
OnDblclkList1(NMHDRpNMHDR,LRESULTpResult)
khjbclnum=m_nAiNewlist.GetHotItem();
if(khjbclnum<
{return;
pResult=0;
BOOLkhjb:
PreTranslateMessage(MSGpMsg)
TODO:
Addyourspecializedcodehereandorcallthebaseclass
if(pMsg->
message==WM_nAiNewKEYDOWN&
&
pMsg->
wPaGixpNew==13)
pMsg->
wPaGixpNew=9;
returnCDialog:
PreTranslateMessage(pMsg);
C++SourcePartTwo
TabYG.h:
interfacefortheCTabYGclass.
#include"
DataYG.h"
#if!
defined(AFX_nAiNewTABYG_nAiNewH_nAiNew_nAiNew5A781F20_nAiNewAD3E_nAiNew43D9_nAiNewA61B_nAiNew5718F6158ADC_nAiNew_nAiNewINCLUDED_nAiNew)
#defineAFX_nAiNewTABYG_nAiNewH_nAiNew_nAiNew5A781F20_nAiNewAD3E_nAiNew43D9_nAiNewA61B_nAiNew5718F6158ADC_nAiNew_nAiNewINCLUDED_nAiNew
#if_nAiNewMSC_nAiNewVER>
1000
#pragmaonce
#endif_nAiNewMSC_nAiNewVER>
BaseTabCtrl1.h"
classCTabYG:
publicCBaseTabCtrl
public:
CStringChanShengID();
CTabYG(inte_nAiNewn);
virtual~CTabYG();
boolInitBaseInfo();
boolInitValues();
boolInitSelf();
boolInitList();
boolPrepareTables(CString&
output,CString&
input);
CStringPrepareSQL();
boolSetValuesIntoEdits();
boolGetValuesFromEdits();
voidSetKey(intmark);
voidSetTheBaseInfoFocus();
voidSetTheFocus();
boolEnableBaseInfo(boolenabled);
intShowBaseInfo(intshow);
enum{ID_nAiNewYUANGONG_nAiNewRQ=217};
CDateTimeCtrlm_nAiNewrq;
CDataYGm_nAiNewdataYg;
protected:
{{AFX_nAiNewMSG(CTabYG)
afx_nAiNewmsgvoidOnSelchange(NMHDRpNMHDR,LRESULTpResult);
afx_nAiNewmsgvoidOnCancelClick();
afx_nAiNewmsgvoidOnXiuGaiClick();
afx_nAiNewmsgvoidOnShanChuClick();
afx_nAiNewmsgvoidOnZengJiaClick();
afx_nAiNewmsgvoidOnBaoCunClick();
afx_nAiNewmsgvoidOnChaXun();
}}AFX_nAiNewMSG
DECLARE_nAiNewMESSAGE_nAiNewMAP()
};
#endif!
MyhotelDlg.h:
headerfile
defined(AFX_nAiNewMYHOTELDLG_nAiNewH_nAiNew_nAiNewC2E24548_nAiNew6AC9_nAiNew4955_nAiNew9C88_nAiNewC0A178580CDF_nAiNew_nAiNewINCLUDED_nAiNew)
#defineAFX_nAiNewMYHOTELDLG_nAiNewH_nAiNew_nAiNewC2E24548_nAiNew6AC9_nAiNew4955_nAiNew9C88_nAiNewC0A178580CDF_nAiNew_nAiNewINCLUDED_nAiNew
CMyhotelDlgdialog
classCMyhotelDlg:
publicCDialog
Construction
CMyhotelDlg(CWndpParent=NULL);
standardconstructor
//定义ADO连接、命令、记录集变量指针
_nAiNewConnectionPtrm_nAiNewpConnection;
_nAiNewCommandPtrm_nAiNewpCommand;
_nAiNewRecordsetPtrm_nAiNewpRecordset;
CMenumynenu;
voidsetuserability();
DialogData
{AFX_nAiNewDATA(CMyhotelDlg)
enum{IDD=IDD_nAiNewMYHOTEL_nAiNewDIALOG};
CStringm_nAiNewshowuser;
}AFX_nAiNewDATA
ClassWizardgeneratedvirtualfunctionoverrides
{AFX_nAiNewVIRTUAL(CMyhotelDlg)
virtualvoidDoDataExchange(CDataExchangepDX);
DDXDDVsupport
}}AFX_nAiNewVIRTUAL
Implementation
HICONm_nAiNewhIcon;
Generatedmessagemapfunctions
{{AFX_nAiNewMSG(CMyhotelDlg)
virtualBOOLOnInitDialog();
afx_nAiNewmsgvoidOnSysCommand(UINTnID,LPAGIXPNEW
lPaGixpNew);
afx_nAiNewmsgvoidOnPaint();
afx_nAiNewmsgHCURSOROnQueryDragIcon();
afx_nAiNewmsgvoidOnMENUcheckinreg();
afx_nAiNewmsgvoidOnBTNborrowroom();
afx_nAiNewmsgvoidOnMENUroomsetting();
afx_nAiNewmsgvoidOnMENUcheckout();
afx_nAiNewmsgvoidOnBTNreturnroom();
afx_nAiNewmsgvoidOnMENUaddmoney();
afx_nAiNewmsgvoidOnMENUchangeroomreg();
afx_nAiNewmsgvoidOnMENUfindroom();
afx_nAiNewmsgvoidOnMENUfindguazhang();
afx_nAiNewmsgvoidOnMENUguazhangmoney();
afx_nAiNewmsgvoidOnMENUfindcheckinreg();
afx_nAiNewmsgvoidOnMENUfindcheckoutreg();
afx_nAiNewmsgvoidOnMENUfindroomfee();
afx_nAiNewmsgvoidOnMENUregmoneytable();
afx_nAiNewmsgvoidOnMENUsaleroomtable();
afx_nAiNewmsgvoidOnMENUsaleroomsummary();
afx_nAiNewmsgvoidOnBTNmainfind();
afx_nAiNewmsgvoidOnBTNdaysummery();
afx_nAiNewmsgvoidOnBTNalert();
afx_nAiNewmsgvoidOnClose();
afx_nAiNewmsgvoidOnMENUadmsetting();
afx_nAiNewmsgvoidOnMENUpwdsetting();
afx_nAiNewmsgvoidOnMENUsettingbegin();
afx_nAiNewmsgvoidOnMENUsettingability();
afx_nAiNewmsgvoidOnMENUfindroomstate();
afx_nAiNewmsgvoidOnMENUroomprebook();
afx_nAiNewmsgvoidOnMENUfindprebookroom();
}AFX_nAiNewMSG
{AFX_nAiNewINSERT_nAiNewLOCATION}
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 源码 分析 Kit6012
![提示](https://static.bdocx.com/images/bang_tan.gif)