home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / msdn_vcb / samples / vc98 / mfc / database / daoctl / control / daoctl.h < prev    next >
C/C++ Source or Header  |  1998-03-26  |  2KB  |  82 lines

  1. // DaoEditCtl.h : Declaration of the CDaoEditCtrl OLE control class.
  2. //
  3. // This is a part of the Microsoft Foundation Classes C++ library.
  4. // Copyright (C) 1992-1998 Microsoft Corporation
  5. // All rights reserved.
  6. //
  7. // This source code is only intended as a supplement to the
  8. // Microsoft Foundation Classes Reference and related
  9. // electronic documentation provided with the library.
  10. // See these sources for detailed information regarding the
  11. // Microsoft Foundation Classes product.
  12.  
  13. /////////////////////////////////////////////////////////////////////////////
  14. // CDaoEditCtrl : See DaoEditCtl.cpp for implementation.
  15.  
  16. class CDaoEditCtrl : public COleControl
  17. {
  18.     DECLARE_DYNCREATE(CDaoEditCtrl)
  19.  
  20. // Constructor
  21. public:
  22.     CDaoEditCtrl();
  23.  
  24. // Overrides
  25.  
  26.     // Drawing function
  27.     virtual void OnDraw(
  28.                 CDC* pdc, const CRect& rcBounds, const CRect& rcInvalid);
  29.  
  30.     // Persistence
  31.     virtual void DoPropExchange(CPropExchange* pPX);
  32.  
  33.     // Reset control state
  34.     virtual void OnResetState();
  35.  
  36. // Implementation
  37. protected:
  38.     ~CDaoEditCtrl();
  39.  
  40.     DECLARE_OLECREATE_EX(CDaoEditCtrl)    // Class factory and guid
  41.     DECLARE_OLETYPELIB(CDaoEditCtrl)      // GetTypeInfo
  42.     DECLARE_PROPPAGEIDS(CDaoEditCtrl)     // Property page IDs
  43.     DECLARE_OLECTLTYPE(CDaoEditCtrl)        // Type name and misc status
  44.  
  45.     // Subclassed control support
  46.     BOOL PreCreateWindow(CREATESTRUCT& cs);
  47.     BOOL IsSubclassedControl();
  48.     LRESULT OnOcmCommand(WPARAM wParam, LPARAM lParam);
  49.  
  50. // Implementation
  51.     BOOL m_bDirty;
  52.  
  53. // Message maps
  54.     //{{AFX_MSG(CDaoEditCtrl)
  55.     afx_msg void OnKillFocus(CWnd* pNewWnd);
  56.     afx_msg void OnChar(UINT nChar, UINT nRepCnt, UINT nFlags);
  57.     afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);
  58.     //}}AFX_MSG
  59.     DECLARE_MESSAGE_MAP()
  60.  
  61. // Dispatch maps
  62.     //{{AFX_DISPATCH(CDaoEditCtrl)
  63.     CString m_strFieldName;
  64.     //}}AFX_DISPATCH
  65.     DECLARE_DISPATCH_MAP()
  66.  
  67.     afx_msg void AboutBox();
  68.  
  69. // Event maps
  70.     //{{AFX_EVENT(CDaoEditCtrl)
  71.     //}}AFX_EVENT
  72.     DECLARE_EVENT_MAP()
  73.  
  74. // Dispatch and event IDs
  75. public:
  76.     enum {
  77.     //{{AFX_DISP_ID(CDaoEditCtrl)
  78.     dispidFieldName = 1L,
  79.     //}}AFX_DISP_ID
  80.     };
  81. };
  82.