home *** CD-ROM | disk | FTP | other *** search
- // commppg.cpp : Implementation of the CCommPropPage property page class.
-
- #include "stdafx.h"
- #include "comm.h"
- #include "commppg.h"
-
- #ifdef _DEBUG
- #undef THIS_FILE
- static char BASED_CODE THIS_FILE[] = __FILE__;
- #endif
-
-
- IMPLEMENT_DYNCREATE(CCommPropPage, COlePropertyPage)
-
-
- /////////////////////////////////////////////////////////////////////////////
- // Message map
-
- BEGIN_MESSAGE_MAP(CCommPropPage, COlePropertyPage)
- //{{AFX_MSG_MAP(CCommPropPage)
- //}}AFX_MSG_MAP
- END_MESSAGE_MAP()
-
-
- /////////////////////////////////////////////////////////////////////////////
- // Initialize class factory and guid
-
- IMPLEMENT_OLECREATE_EX(CCommPropPage, "COMM.CommPropPage.1",
- 0x5b83b084, 0x14f0, 0x11ce, 0x96, 0xf, 0x52, 0x41, 0x53, 0x48, 0x0, 0x5)
-
-
- /////////////////////////////////////////////////////////////////////////////
- // CCommPropPage::CCommPropPageFactory::UpdateRegistry -
- // Adds or removes system registry entries for CCommPropPage
-
- BOOL CCommPropPage::CCommPropPageFactory::UpdateRegistry(BOOL bRegister)
- {
- if (bRegister)
- return AfxOleRegisterPropertyPageClass(AfxGetInstanceHandle(),
- m_clsid, IDS_COMM_PPG);
- else
- return AfxOleUnregisterClass(m_clsid, NULL);
- }
-
-
- /////////////////////////////////////////////////////////////////////////////
- // CCommPropPage::CCommPropPage - Constructor
-
- CCommPropPage::CCommPropPage() :
- COlePropertyPage(IDD, IDS_COMM_PPG_CAPTION)
- {
- //{{AFX_DATA_INIT(CCommPropPage)
- m_phoneNumber = _T("");
- //}}AFX_DATA_INIT
- }
-
-
- /////////////////////////////////////////////////////////////////////////////
- // CCommPropPage::DoDataExchange - Moves data between page and properties
-
- void CCommPropPage::DoDataExchange(CDataExchange* pDX)
- {
- //{{AFX_DATA_MAP(CCommPropPage)
- DDP_Text(pDX, IDC_PHONE1, m_phoneNumber, _T("PhoneNumber") );
- DDX_Text(pDX, IDC_PHONE1, m_phoneNumber);
- DDV_MaxChars(pDX, m_phoneNumber, 14);
- //}}AFX_DATA_MAP
- DDP_PostProcessing(pDX);
- }
-
-
- /////////////////////////////////////////////////////////////////////////////
- // CCommPropPage message handlers
-
-