WnvRequestNotification function (wnvapi.h)

Requests notification from the Windows Network Virtualization (WNV) driver whenever a certain type of event occurs.

Syntax

ULONG WnvRequestNotification(
  HANDLE                  WnvHandle,
  PWNV_NOTIFICATION_PARAM NotificationParam,
  LPOVERLAPPED            Overlapped,
  PULONG                  BytesTransferred
);

Parameters

WnvHandle

Type: HANDLE

An object handle that is returned from a call to the WnvOpen function.

NotificationParam

Type: PWNV_NOTIFICATION_PARAM

A pointer to the notification type for the request.

Overlapped

Type: LPOVERLAPPED

Information about the asynchronous completion of this request. If this parameter is NULL, the request is synchronous.

BytesTransferred

Type: PULONG

When this function returns, the BytesTransferred parameter points to the size of the buffer that is filled with the notification structures of the specific event type.

Return value

Type: ULONG

If the operation succeeds, the function returns ERROR_SUCCESS.

If the operation fails, the function returns one of the following system error codes.

Return code Description
ERROR_INVALID_PARAMETER
There is a problem with the NotificationParam parameter, in the WNV_NOTIFICATION_PARAM structure's Header field:

Remarks

This function can be called synchronously or asynchronously.

Three notification types are defined in the WNV_NOTIFICATION_PARAM structure. Each call to this function can request only one type of notification. To receive multiple notification types, the process must make one call for each notification on the same handle. The WNV driver returns at least one notification of the type specified in each call when the notification events occur.

Requirements

Requirement Value
Minimum supported client None supported
Minimum supported server Windows Server 2012 [desktop apps only]
Target Platform Windows
Header wnvapi.h
DLL Wnvapi.dll