SHNotificationAdd
This function adds a notification (asynchronously) to the notification tray.
LRESULT SHNotificationAdd(
SHNOTIFICATIONDATA * pndAdd
);
Parameters
- pndAdd
Reference to the notification to be added.
Return Values
ERROR_SUCCESS indicates success.
Remarks
This API is called to add a notification to the tray. Notification processing is done asynchronously; that is, this function will return after adding the notification to the tray, and processing will happen on a different thread.
To customize the physical behaviour for a notification, create a CLSID for the notification class (passed into SHNotificationAdd), and create the registry key:
[HKEY_CURRENT_USER\ControlPanel\Notifications\{CLSID}]
@="Name" ; this is what appears in Settings - if you don't want to allow user customization, don't add this default value
"Options"=dword:1 ; notification flags
"Duration"=dword:0 ; duration in minutes of LED flashing
"Wave"="wavefile" ; default is in the Windows folder. There is no extension on the file
The following table lists the possible values for the Options parameter.
Notification flag | Value | Description |
---|---|---|
NOTIF_SOUND | 0x00000001 | Sound notification. |
NOTIF_VIBRATE | 0x00000002 | Vibrate notification. |
NOTIF_FLASH | 0x00000004 | ROM notification. |
NOTIF_MESSAGE | 0x00000008 | Message notification. |
Requirements
Smartphone: Not Supported
Pocket PC: Windows Mobile 2002 and later
OS Versions: Windows CE 3.0 and later
Header: aygshell.h
Library: aygshell.lib
Send feedback on this topic to the authors.
© 2005 Microsoft Corporation. All rights reserved.