PrintNotificationEventDetails PrintNotificationEventDetails PrintNotificationEventDetails PrintNotificationEventDetails Class


Contains properties that allow a client to access and/or manipulate print event data and print device name information.

public : sealed class PrintNotificationEventDetails : IPrintNotificationEventDetailspublic sealed class PrintNotificationEventDetails : IPrintNotificationEventDetailsPublic NotInheritable Class PrintNotificationEventDetails Implements IPrintNotificationEventDetails// You can use this class in JavaScript.
Windows 10 requirements
Device family
Windows Desktop Extension SDK (introduced v10.0.10240.0)
API contract
Windows.Devices.Printers.Extensions.ExtensionsContract (introduced v1)


Background task handlers can use local storage to save the PrinterName and EventData values of the PrintNotificationEventDetails class, so that the information can be used later by an app.

    // Save the printer name and asyncUI xml
    var keyPrinterName = "BA5857FA-DE2C-4A4A-BEF2-49D8B4130A39";
    var keyAsyncUIXML = "55DCA47A-BEE9-43EB-A7C8-92ECA2FA0685";
    var settings = Windows.Storage.ApplicationData.current.localSettings;

    // The background task instance's activation parameters are available
    // via Windows.UI.WebUI.WebUIBackgroundTaskInstance.current
    var backgroundTaskInstance = Windows.UI.WebUI.WebUIBackgroundTaskInstance.current;

    // Save data into a user-defined var, "settings" 
    var details = backgroundTaskInstance.triggerDetails;
    settings.values[keyPrinterName] = details.printerName;
    settings.values[keyAsyncUIXML] = details.eventData;

    // Save directly into PrintNotificationEventDetails
    Windows.Devices.Printers.Extensions.PrintNotificationEventDetails = details;

For more information about using the PrintNotificationEventDetails class, see the Windows Store device apps for printers topic on the Hardware Dev Center.


EventData EventData EventData EventData

Gets or sets the event data for a print notification event.

public : PlatForm::String EventData { get; set; }public string EventData { get; set; }Public ReadWrite Property EventData As string// You can use this property in JavaScript.
PlatForm::String string string string

The print notification event data.


The property is nested XML that is formatted as string. To get this property, parse for the Bidi request and response schema that is embedded in an <Envelope>, following the AsyncUI's balloonUI element message, which contains the action element. The action element contains the <Envelope> where the Bidi response schema is found. Examine the Bidi response to determine the cause of the event.

PrinterName PrinterName PrinterName PrinterName

Gets the name of the print device associated with the print notification.

public : PlatForm::String PrinterName { get; }public string PrinterName { get; }Public ReadOnly Property PrinterName As string// You can use this property in JavaScript.
PlatForm::String string string string

The print device name.

See Also