📄 dlgnew.cpp
字号:
// DlgNew.cpp : implementation file
//
#include "stdafx.h"
#include "wastebook.h"
#include "DlgNew.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CDlgNew dialog
CDlgNew::CDlgNew(CWnd* pParent /*=NULL*/)
: CDialog(CDlgNew::IDD, pParent)
{
//{{AFX_DATA_INIT(CDlgNew)
m_Type = _T("");
m_Num = 0;
m_Date = 0;
m_Name = _T("");
//}}AFX_DATA_INIT
}
void CDlgNew::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CDlgNew)
DDX_Control(pDX, IDC_COMBO_Type, m_ctrlType);
DDX_CBString(pDX, IDC_COMBO_Type, m_Type);
DDV_MaxChars(pDX, m_Type, 30);
DDX_Text(pDX, IDC_EDIT_Number, m_Num);
DDX_DateTimeCtrl(pDX, IDC_DATETIMEPICKER, m_Date);
DDX_Text(pDX, IDC_EDIT_Name, m_Name);
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CDlgNew, CDialog)
//{{AFX_MSG_MAP(CDlgNew)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CDlgNew message handlers
BOOL CDlgNew::OnInitDialog()
{
CDialog::OnInitDialog();
// TODO: Add extra initialization here
m_ctrlType.ResetContent();
if(!bAddIncome)
{
int l=theApp.InListType.GetCount();
POSITION pos=theApp.InListType.GetHeadPosition();
for(int i=0;i<l;i++)
m_ctrlType.AddString(theApp.InListType.GetNext(pos));
}
else
{
int l=theApp.OutListType.GetCount();
POSITION pos=theApp.OutListType.GetHeadPosition();
for(int i=0;i<l;i++)
m_ctrlType.AddString(theApp.OutListType.GetNext(pos));
}
m_ctrlType.SetWindowText(m_Type);
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -