www.pudn.com > C_modem16.zip > PAGEC.CPP


// pagec.cpp : implementation file 
// 
 
#include "stdafx.h" 
#include "modem16.h" 
#include "pagec.h" 
 
#ifdef _DEBUG 
#undef THIS_FILE 
static char BASED_CODE THIS_FILE[] = __FILE__; 
#endif 
 
///////////////////////////////////////////////////////////////////////////// 
// PageC dialog 
 
 
PageC::PageC(CWnd* pParent /*=NULL*/) 
	: CDialog(PageC::IDD, pParent) 
{ 
	//{{AFX_DATA_INIT(PageC) 
	m_databits = -1; 
	m_parity = -1; 
	m_stopbits = -1; 
	m_command = ""; 
	m_baud = ""; 
	m_com = ""; 
	//}}AFX_DATA_INIT 
} 
 
void PageC::DoDataExchange(CDataExchange* pDX) 
{ 
	CDialog::DoDataExchange(pDX); 
	//{{AFX_DATA_MAP(PageC) 
	DDX_Control(pDX, IDC_COM, m_com1); 
	DDX_Radio(pDX, IDC_DATABITS, m_databits); 
	DDX_Radio(pDX, IDC_PARITY, m_parity); 
	DDX_Radio(pDX, IDC_STOPBITS, m_stopbits); 
	DDX_Text(pDX, IDC_COMMAND, m_command); 
	DDX_CBString(pDX, IDC_BAUD, m_baud); 
	DDX_LBString(pDX, IDC_COM, m_com); 
	//}}AFX_DATA_MAP 
} 
 
BEGIN_MESSAGE_MAP(PageC, CDialog) 
	//{{AFX_MSG_MAP(PageC) 
	//}}AFX_MSG_MAP 
END_MESSAGE_MAP() 
 
 
///////////////////////////////////////////////////////////////////////////// 
// PageC message handlers 
 
 
BOOL PageC::OnInitDialog() 
{ 
	CDialog::OnInitDialog(); 
	 
	// TODO: Add extra initialization here 
	m_com1.AddString("None"); 
	m_com1.AddString("Com1"); 
	m_com1.AddString("Com2"); 
	m_com1.AddString("Com3"); 
	m_com1.AddString("Com4"); 
	m_com1.SelectString(-1,m_com.GetBuffer(10)); 
	return TRUE;  // return TRUE  unless you set the focus to a control 
}