DataProvidersOptions.h
上传用户:szled88
上传日期:2015-04-09
资源大小:43957k
文件大小:3k
源码类别:

对话框与窗口

开发平台:

Visual C++

  1. // DataProvidersOptions.h : header file
  2. //
  3. // This file is a part of the XTREME TOOLKIT PRO MFC class library.
  4. // (c)1998-2008 Codejock Software, All Rights Reserved.
  5. //
  6. // THIS SOURCE FILE IS THE PROPERTY OF CODEJOCK SOFTWARE AND IS NOT TO BE
  7. // RE-DISTRIBUTED BY ANY MEANS WHATSOEVER WITHOUT THE EXPRESSED WRITTEN
  8. // CONSENT OF CODEJOCK SOFTWARE.
  9. //
  10. // THIS SOURCE CODE CAN ONLY BE USED UNDER THE TERMS AND CONDITIONS OUTLINED
  11. // IN THE XTREME TOOLKIT PRO LICENSE AGREEMENT. CODEJOCK SOFTWARE GRANTS TO
  12. // YOU (ONE SOFTWARE DEVELOPER) THE LIMITED RIGHT TO USE THIS SOFTWARE ON A
  13. // SINGLE COMPUTER.
  14. //
  15. // CONTACT INFORMATION:
  16. // support@codejock.com
  17. // http://www.codejock.com
  18. //
  19. /////////////////////////////////////////////////////////////////////////////
  20. #if !defined(AFX_DATAPROVIDERSOPTIONS_H__9B7BA3B9_84AF_425E_9155_1885179FBF51__INCLUDED_)
  21. #define AFX_DATAPROVIDERSOPTIONS_H__9B7BA3B9_84AF_425E_9155_1885179FBF51__INCLUDED_
  22. #if _MSC_VER > 1000
  23. #pragma once
  24. #endif // _MSC_VER > 1000
  25. /////////////////////////////////////////////////////////////////////////////
  26. // CDataProvidersOptions dialog
  27. class CDataProvidersOptions : public CDialog
  28. {
  29. // Construction
  30. public:
  31. CDataProvidersOptions(CWnd* pParent = NULL);   // standard constructor
  32. /// Input 
  33. /// dialog settings
  34. enum {modeMemOnly, modeDBOnly, modeAll};
  35. int m_eMode;
  36.     
  37. BOOL m_bWarnIfExist; // = FALSE
  38. BOOL m_bOpenMode; // = FALSE
  39. CString m_strTitle; // = "Select data provider and data file"
  40. // Data Parameters
  41. BOOL m_bInitFromProfile; // = TRUE
  42. BOOL m_bSaveToProfile; // = TRUE
  43. // Input-Output
  44. CString m_strConnectionString; // = ""
  45. /// Results
  46. BOOL IsDPWasChanged() const;
  47. BOOL IsFileWasChanged() const;
  48. protected:
  49. // Dialog Data
  50. //{{AFX_DATA(CDataProvidersOptions)
  51. enum { IDD = IDD_DATA_PROVIDER_OPTIONS };
  52. CButton m_ctrlOK;
  53. CButton m_ctrlUseMemDP;
  54. CButton m_ctrlMemFrame;
  55. CStatic m_ctrlMemFileLabel;
  56. CEdit m_ctrlMemFile;
  57. CButton m_ctrlMemFileBrowse;
  58. CStatic m_ctrlMemFileHelp;
  59. CButton m_ctrlUseDBDP;
  60. CButton m_ctrlDBFrame;
  61. CStatic m_ctrlDBFileLabel;
  62. CEdit m_ctrlDBFile;
  63. CButton m_ctrlDBFileBrowse;
  64. CStatic m_ctrlDBFileHelp;
  65. CButton m_ctrlUseMAPIDP;
  66. CButton m_ctrlMAPIFrame;
  67. CStatic m_ctrlMAPILabel;
  68. //}}AFX_DATA
  69. BOOL m_bIsDPWasChanged;
  70. BOOL m_bIsFileWasChanged;
  71. CString m_strUseDP_Prev;
  72. CString m_strMemDPFile_Prev;
  73. CString m_strDBDPFile_Prev;
  74. // Overrides
  75. // ClassWizard generated virtual function overrides
  76. //{{AFX_VIRTUAL(CDataProvidersOptions)
  77. protected:
  78. virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
  79. //}}AFX_VIRTUAL
  80. // Implementation
  81. protected:
  82. BOOL CheckExist(LPCTSTR pcszFile);
  83. void EnableDBDPcontrols(BOOL bEnable);
  84. void EnableMemDPcontrols(BOOL bEnable);
  85. void EnableMAPIDPcontrols(BOOL bEnable);
  86. CString FileBrowse(const CString& strFileName, const CString& strDefExt, 
  87. const CString& strFilter);
  88. // Generated message map functions
  89. //{{AFX_MSG(CDataProvidersOptions)
  90. virtual BOOL OnInitDialog();
  91. virtual void OnOK();
  92. afx_msg void OnMemDPFileBrowse();
  93. afx_msg void OnDBDPFileBrowse();
  94. afx_msg void OnUseDBDP();
  95. afx_msg void OnUseMemDP();
  96. afx_msg void OnUseMAPIDP();
  97. virtual void OnCancel();
  98. //}}AFX_MSG
  99. DECLARE_MESSAGE_MAP()
  100. };
  101. //{{AFX_INSERT_LOCATION}}
  102. // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
  103. #endif // !defined(AFX_DATAPROVIDERSOPTIONS_H__9B7BA3B9_84AF_425E_9155_1885179FBF51__INCLUDED_)