www.pudn.com > StuMis.rar > JWinputDlg.cpp
// JWinputDlg.cpp : implementation file
//
#include "stdafx.h"
#include "StuMis.h"
#include "JWinputDlg.h"
#include "INIDDlg.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
extern CStuMisApp theApp;
/////////////////////////////////////////////////////////////////////////////
// CJWinputDlg property page
IMPLEMENT_DYNCREATE(CJWinputDlg, CPropertyPage)
CJWinputDlg::CJWinputDlg() : CPropertyPage(CJWinputDlg::IDD)
{
//{{AFX_DATA_INIT(CJWinputDlg)
m_inputid = _T("");
//}}AFX_DATA_INIT
}
CJWinputDlg::~CJWinputDlg()
{
}
void CJWinputDlg::DoDataExchange(CDataExchange* pDX)
{
CPropertyPage::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CJWinputDlg)
DDX_Text(pDX, IDC_INEDITID, m_inputid);
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CJWinputDlg, CPropertyPage)
//{{AFX_MSG_MAP(CJWinputDlg)
ON_WM_PAINT()
ON_BN_CLICKED(IDC_INID, OnInid)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CJWinputDlg message handlers
BOOL CJWinputDlg::OnInitDialog()
{
CPropertyPage::OnInitDialog();
m_Sheet.AddPage(&m_xujichangedlg); // 加第1页
m_Sheet.AddPage(&m_moneydlg); // 加第2页
m_Sheet.AddPage(&m_punishdlg); // 加第3页
// 加第4页
m_Sheet.Create(this, WS_CHILD | WS_VISIBLE, 0); // 创建窗口
m_Sheet.ModifyStyleEx (0, WS_EX_CONTROLPARENT); // 修改风格
m_Sheet.ModifyStyle( 0, WS_TABSTOP ); // 修改风格
// 设置窗口位置
m_Sheet.SetWindowPos( NULL, -6, 20, 0, 0,
SWP_NOZORDER | SWP_NOSIZE | SWP_NOACTIVATE );
for(int i=0;i<3;i++)
{
m_Sheet.SetActivePage(i);
}
m_Sheet.SetActivePage(0);
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
void CJWinputDlg::OnPaint()
{
CPaintDC dc(this); // device context for painting
// TODO: Add your message handler code here
// CINIDDlg dlg;
// dlg.DoModal();
// Do not call CPropertyPage::OnPaint() for painting messages
}
void CJWinputDlg::OnInid()
{
UpdateData();
m_xujichangedlg.m_sid=m_inputid;
m_xujichangedlg.UpdateData(FALSE);
m_moneydlg.m_sid=m_inputid;
m_moneydlg.UpdateData(FALSE);
//
m_punishdlg.m_sid=m_inputid;
m_punishdlg.UpdateData(FALSE);
// TODO: Add your control notification handler code here
m_moneydlg.UpdateList();
m_xujichangedlg.UpdateList();
m_punishdlg.UpdateList();
// m_moneydlg.UpdateList();
}