Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

144 lines
4.0 KiB

  1. /*++
  2. Copyright (C) 1998-1999 Microsoft Corporation
  3. Module Name:
  4. alrtactp.h
  5. Abstract:
  6. Header file for the alert actions property page.
  7. --*/
  8. #if !defined(_AFX_ALRTACTP_H__INCLUDED_)
  9. #define _AFX_ALRTACTP_H__INCLUDED_
  10. #if _MSC_VER >= 1000
  11. #pragma once
  12. #endif // _MSC_VER >= 1000
  13. #include "smalrtq.h" // For PALERT_ACTION_INFO
  14. #include "smproppg.h" // Base class
  15. #include "smcfghlp.h"
  16. // Dialog controls
  17. #define IDD_ALERT_ACTION_PROP 1600
  18. #define IDC_ACTION_CAPTION 1601
  19. #define IDC_ACTION_CMD_ARGS_CAPTION 1602
  20. #define IDC_ACTION_FIRST_HELP_CTRL_ID 1603
  21. #define IDC_ACTION_APPLOG_CHK 1603
  22. #define IDC_ACTION_NETMSG_CHK 1604
  23. #define IDC_ACTION_NETMSG_NAME_EDIT 1605
  24. #define IDC_ACTION_EXECUTE_CHK 1606
  25. #define IDC_ACTION_EXECUTE_EDIT 1607
  26. #define IDC_ACTION_EXECUTE_BROWSE_BTN 1608
  27. #define IDC_ACTION_CMD_ARGS_BTN 1609
  28. #define IDC_ACTION_START_LOG_CHK 1610
  29. #define IDC_ACTION_START_LOG_COMBO 1611
  30. #define IDC_ACTION_CMD_ARGS_DISPLAY 1612
  31. class CSmAlertQuery;
  32. class CAlertCommandArgsDlg;
  33. /////////////////////////////////////////////////////////////////////////////
  34. // CAlertActionProp dialog
  35. class CAlertActionProp : public CSmPropertyPage
  36. {
  37. DECLARE_DYNCREATE(CAlertActionProp)
  38. friend class CAlertCommandArgsDlg;
  39. // Construction
  40. public:
  41. CAlertActionProp();
  42. CAlertActionProp(MMC_COOKIE mmcCookie, LONG_PTR hConsole);
  43. virtual ~CAlertActionProp();
  44. // Dialog Data
  45. //{{AFX_DATA(CAlertActionProp)
  46. enum { IDD = IDD_ALERT_ACTION_PROP };
  47. CComboBox m_pLogCombo;
  48. BOOL m_Action_bLogEvent;
  49. BOOL m_Action_bExecCmd;
  50. BOOL m_Action_bSendNetMsg;
  51. BOOL m_Action_bStartLog;
  52. CString m_Action_strCmdPath;
  53. CString m_Action_strNetName;
  54. INT m_nCurLogSel;
  55. BOOL m_CmdArg_bAlertName;
  56. BOOL m_CmdArg_bDateTime;
  57. BOOL m_CmdArg_bLimitValue;
  58. BOOL m_CmdArg_bCounterPath;
  59. BOOL m_CmdArg_bSingleArg;
  60. BOOL m_CmdArg_bMeasuredValue;
  61. BOOL m_CmdArg_bUserText;
  62. CString m_CmdArg_strUserText;
  63. CString m_strCmdArgsExample;
  64. //}}AFX_DATA
  65. // Overrides
  66. // ClassWizard generate virtual function overrides
  67. //{{AFX_VIRTUAL(CAlertActionProp)
  68. public:
  69. protected:
  70. virtual BOOL OnApply();
  71. virtual void OnCancel();
  72. virtual BOOL OnInitDialog();
  73. virtual BOOL OnSetActive();
  74. virtual BOOL OnKillActive();
  75. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  76. //}}AFX_VIRTUAL
  77. // Implementation
  78. public:
  79. void MakeTimeString(CString *pTimeString);
  80. PALERT_ACTION_INFO m_pAlertInfo;
  81. protected:
  82. virtual INT GetFirstHelpCtrlId ( void ) { return IDC_ACTION_FIRST_HELP_CTRL_ID; }; // Subclass must override.
  83. virtual BOOL IsValidLocalData();
  84. // Generated message map functions
  85. //{{AFX_MSG(CAlertActionProp)
  86. afx_msg void OnActionExecuteBrowseBtn();
  87. afx_msg void OnActionApplogChk();
  88. afx_msg void OnActionNetmsgChk();
  89. afx_msg void OnActionExecuteChk();
  90. afx_msg void OnActionCmdArgsBtn();
  91. afx_msg void OnActionStartLogChk();
  92. afx_msg void OnNetNameTextEditChange();
  93. afx_msg void OnCmdPathTextEditChange();
  94. afx_msg void OnSelendokStartLogCombo();
  95. //}}AFX_MSG
  96. DECLARE_MESSAGE_MAP()
  97. BOOL LoadLogQueries ( DWORD dwLogType );
  98. BOOL SetControlState(void);
  99. private:
  100. DWORD MakeSampleArgList (
  101. CString& rstrResult,
  102. const BOOL bSingleArg,
  103. const BOOL bAlertName,
  104. const BOOL bDateTime,
  105. const BOOL bCounterPath,
  106. const BOOL bMeasuredValue,
  107. const BOOL bLimitValue,
  108. const BOOL bUserText,
  109. const CString& rstrUserText );
  110. void InitAfxDataItems (void);
  111. void UpdateCmdActionBox (void);
  112. CSmAlertQuery *m_pAlertQuery;
  113. };
  114. //{{AFX_INSERT_LOCATION}}
  115. // Microsoft Developer Studio will insert additional declarations immediately before the previous line.
  116. #endif // !defined(_AFX_ALRTACTP_H__INCLUDED_)