RouterCreatePrintAsyncNotificationChannel function

The RouterCreatePrintAsyncNotificationChannel function creates an asynchronous notification channel that is associated with a printer or print server.

Syntax

HRESULT RouterCreatePrintAsyncNotificationChannel(
  PCWSTR                            pName,
  PrintAsyncNotificationType        *pNotificationType,
  PrintAsyncNotifyUserFilter        eNotifyFilter,
  PrintAsyncNotifyConversationStyle eConversationStyle,
  IPrintAsyncNotifyCallback         *pCallback,
  IPrintAsyncNotifyChannel          **ppIAsynchNotification
);

Parameters

pName

A pointer to a null-terminated string that specifies the name of the printer or print server.

pNotificationType

A pointer to a GUID that represents the type of notifications sent through this channel.

eNotifyFilter

eConversationStyle

The type of communication: unidirectional or bidirectional.

pCallback

A pointer to the callback function that is called to deliver the response notifications, when bidirectional communication is in effect. This parameter is ignored when unidirectional communication is in effect.

ppIAsynchNotification

Return Value

RouterCreatePrintAsyncNotificationChannel returns S_OK on success and returns a standard COM error code otherwise.

Remarks

In some cases, you must release the channel that you created with the RouterCreatePrintAsyncNotificationChannel function by calling Release on IPrintAsyncNotifyChannel. For information about when to release a channel, see Notification Channel.

Requirements

   
Target Platform Desktop
Header prnasntp.h (include Prnasntp.h)
Library Spoolss.lib
DLL Spoolss.dll