NtDllNtOpenEvent(IntPtr, EventAccessRights, ObjectAttributes) Method

Opens a handle to an existing named event object with the specified desired access.

Definition

Namespace: DevCase.Win32.NativeMethods
Assembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[DllImportAttribute("NtDll.dll")]
public static NTStatus NtOpenEvent(
	out IntPtr refEventHandle,
	EventAccessRights desiredAccess,
	in ObjectAttributes refObjectAttributes
)

Parameters

refEventHandle  IntPtr
A pointer to a variable that will receive the event object handle.

The handle includes bookkeeping information, such as a reference count and security context.

desiredAccess  EventAccessRights
The access mask value that represents the desired types of access for the event object.
refObjectAttributes  ObjectAttributes
A pointer to the ObjectAttributes structure that the caller supplied to be used for the specified object.

These attributes would include the ObjectName and the handle attributes, for example. This parameter is initialized by calling the InitializeObjectAttributes macro.

Return Value

NTStatus
Returns SUCCESS on success, or the appropriate NTStatus error code on failure.

Remarks

See Also