OPCAE.NET Reference Manual
QueryEventCategories Method
See Also  Send Feedback
OPCAE.NET Namespace > OpcEventServer Class : QueryEventCategories Method

EventType
A bit mask specifying which event types are of interest: OPC_SIMPLE_EVENT, OPC_CONDITION_EVENT, OPC_TRACKING_EVENT, OPC_ALL_EVENTS. These types can be OR’ed together to select multiple event types. A value of 0 is an error and causes E_INVALIDARG to be returned.
EventCategories
Array of identifiers for the vendor-specific event categories implemented by the server. These IDs can be used in the event subscription interface for specifying filters. Category IDs must be unique across the server (e.g. if Category ID x is used for both simple events and condition events, then the ID must reference the exact same category.)
EventCategoryDescs
Array of strings for the text names or descriptions for each of the event category IDs. This array corresponds to the EventCategories array.

Glossary Item Box

The QueryEventCategories method gives clients a means of finding out the specific categories of events supported by a given server. This method would typically be invoked prior to specifying an event filter. Servers will be able to define their own custom event categories, but a list of recommended categories is provided.

Syntax

Visual Basic (Declaration) 
Public Function QueryEventCategories( _
   ByVal EventType As OPCAE.OPCAEEventType, _
   ByRef EventCategories As Integer(), _
   ByRef EventCategoryDescs As String() _
) As Integer
C# 
public int QueryEventCategories( 
   OPCAE.OPCAEEventType EventType,
   out int[] EventCategories,
   out string[] EventCategoryDescs
)

Parameters

EventType
A bit mask specifying which event types are of interest: OPC_SIMPLE_EVENT, OPC_CONDITION_EVENT, OPC_TRACKING_EVENT, OPC_ALL_EVENTS. These types can be OR’ed together to select multiple event types. A value of 0 is an error and causes E_INVALIDARG to be returned.
EventCategories
Array of identifiers for the vendor-specific event categories implemented by the server. These IDs can be used in the event subscription interface for specifying filters. Category IDs must be unique across the server (e.g. if Category ID x is used for both simple events and condition events, then the ID must reference the exact same category.)
EventCategoryDescs
Array of strings for the text names or descriptions for each of the event category IDs. This array corresponds to the EventCategories array.

Return Value

HRESULTS error/success code.

Requirements

Target Platforms: Windows 7/8/10, Windows Server 2003/2008/2012/2016, .NET 4.x

See Also

© 2002-2018 Advosol Inc. All Rights Reserved.