Signal Method of the IFPCEventDefinition Interface

The Signal method signals the event on the local server. If an alert exists for the event and the conditions for issuing the alert are met, actions may be taken to notify the administrator of the event. Third-party filters can also use this method to signal an event.

C++

Syntax

HRESULT Signal(
  [in, optional]  long SignalCount,
  [in, optional]  long AdditionalKey,
  [in, optional]  BSTR ShortDesc,
  [in, optional]  BSTR LongDesc,
  [in, optional]  long EventID,
  [in, optional]  BSTR EventSource,
  [in, optional]  VARIANT EventStrings,
  [in, optional]  VARIANT EventData,
  [in, optional]  short EventCategory,
  [in, optional]  short EventType
);

Parameters

  • SignalCount
    The number of instances of the event to be signaled. The default value is 1.

  • AdditionalKey
    An additional key (index) from the table of subevents for the event. This parameter cannot be set to 0. The default value is -1.

  • ShortDesc
    BSTR that provides a brief description of the run-time event. This description is used as the subject line of an e-mail message sent in a send-mail action. The default value is an empty string.

  • LongDesc
    BSTR that provides a detailed description of the run-time event. This description is used as the body of an e-mail message sent in a send-mail action. The default value is an empty string.

  • EventID
    A 32-bit integer that specifies the identifier (ID) of the event to be reported to the system event log. The default value is 0.

  • EventSource
    BSTR that specifies the name of a registered event source (application, service, or add-in) to be recorded in the Windows event log as the source of the event. The source name must be included in the following registry value:

    HKLM\SYSTEM\CurrentControlSet\Services\
         Eventlog\Application(System)\Sources

    This parameter is required if the event triggers an alert whose actions include recording events in the Windows event log. The default value is an empty string.

  • EventStrings
    Variant that contains insertion strings for the event.

  • EventData
    Variant that contains raw data for the event.

  • EventCategory
    A 16-bit integer that specifies the category of the event. The default value is 0.

  • EventType
    A 16-bit integer that specifies the type of the event. The default value is 0.

Return Value

This method returns S_OK if the call is successful; otherwise, it returns an error code.

Visual Basic

Syntax

Sub Signal( _
  [ ByVal SignalCount As Long ], _
  [ ByVal AdditionalKey As Long ], _
  [ ByVal ShortDesc As String ], _
  [ ByVal LongDesc As String ], _
  [ ByVal EventID As Long ], _
  [ ByVal EventSource As String ], _
  [ ByVal EventStrings As Variant ], _
  [ ByVal EventData As Variant ], _
  [ ByVal EventCategory As Integer ], _
  [ ByVal EventType As Integer ] _
)

Parameters

  • SignalCount
    The number of instances of the event to be signaled. The default value is 1.

  • AdditionalKey
    An additional key (index) from the table of subevents for the event. This parameter cannot be set to 0. The default value is -1.

  • ShortDesc
    String value that provides a brief description of the run-time event. This description is used as the subject line of an e-mail message sent in a send-mail action. The default value is an empty string.

  • LongDesc
    String value that provides a detailed description of the run-time event. This description is used as the body of an e-mail message sent in a send-mail action. The default value is an empty string.

  • EventID
    A 32-bit integer that specifies the identifier (ID) of the event to be reported to the system event log. The default value is 0.

  • EventSource
    String value that specifies the name of a registered event source (application, service, or add-in) to be recorded in the Windows event log as the source of the event. The source name must be included in the following registry value:

    HKLM\SYSTEM\CurrentControlSet\Services\
         Eventlog\Application(System)\Sources

    This parameter is required if the event triggers an alert whose actions include recording events in the Windows event log. The default value is an empty string.

  • EventStrings
    Variant that contains insertion strings for the event.

  • EventData
    Variant that contains raw data for the event.

  • EventCategory
    A 16-bit integer that specifies the category of the event. The default value is 0.

  • EventType
    A 16-bit integer that specifies the type of the event. The default value is 0.

Return Value

This method has no return values. If the call is unsuccessful, an error is raised that can be intercepted by using an error handler.

Remarks

The EventSource parameter is similar to the lpSourceName parameter of the Windows RegisterEventSource function. Other parameters for this function are similar to parameters in the Windows ReportEvent function, as shown in the following table. For more information, see the relevant function in MSDN.

Signal parameter ReportEvent parameter
EventID dwEventID
EventStrings lpStrings
EventData lpRawData
EventCategory wCategory
EventType wType

Network data (including URLs and other data that comes from untrusted sources) should not be included in the EventStrings parameter for logging, because this can create a security risk. Such data, however, can be included in the RawData parameter for logging.

Requirements

Client Requires Windows 7 or Windows Vista.
Server Requires Windows Server 2008 R2 or Windows Server 2008 x64 Edition with SP2.
Version Requires Forefront Threat Management Gateway (TMG) 2010.
IDL

Declared in Msfpccom.idl.

DLL

Requires Msfpccom.dll.

See Also

FPCEventDefinition

Send comments about this topic to Microsoft

Build date: 6/30/2010