📄 expenregdlg.cpp
字号:
// ExpenRegDlg.cpp : implementation file
//
#include "stdafx.h"
#include "VIPe.h"
#include "ExpenRegDlg.h"
#include ".\expenregdlg.h"
// CExpenRegDlg dialog
IMPLEMENT_DYNAMIC(CExpenRegDlg, CDialog)
CExpenRegDlg::CExpenRegDlg(CWnd* pParent /*=NULL*/)
: CDialog(CExpenRegDlg::IDD, pParent)
, m_strName(_T(""))
, m_strCardNo(_T(""))
, m_strMoney(_T(""))
{
}
CExpenRegDlg::~CExpenRegDlg()
{
}
void CExpenRegDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
DDX_Text(pDX, IDC_NAME, m_strName);
DDX_Text(pDX, IDC_CARDNO, m_strCardNo);
DDX_Text(pDX, IDC_MONEY, m_strMoney);
DDX_Control(pDX, IDC_DESC, m_CtrlSociety);
}
BEGIN_MESSAGE_MAP(CExpenRegDlg, CDialog)
END_MESSAGE_MAP()
// CExpenRegDlg message handlers
BOOL CExpenRegDlg::OnInitDialog()
{
CDialog::OnInitDialog();
int i, nIdx;
for(i=0;i<m_saSocietyName.GetSize();i++){
nIdx = m_CtrlSociety.AddString(m_saSocietyName.GetAt(i));
m_CtrlSociety.SetItemData(nIdx, m_suSocietyID.GetAt(i));
}
m_CtrlSociety.SetCurSel(0);
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
void CExpenRegDlg::OnOK()
{
// TODO: Add your specialized code here and/or call the base class
UpdateData();
int nIdx = m_CtrlSociety.GetCurSel();
if(-1 != nIdx){
char szSocietyID[256] = {0};
UINT uSocietyID;
if(-1 != nIdx){
uSocietyID = m_CtrlSociety.GetItemData(nIdx);
m_uSocietyID = uSocietyID;
}
}
CDialog::OnOK();
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -