Important: The information in this document is obsolete and should not be used for new development.
Installing a Notification Request
To add a notification request to the notification queue, call theNMInstall
function. For example, you can install the notification request defined in Listing 5-1 with the following line of code:
myErr := NMInstall(@gMyNotification); {install request}If the call toNMInstall
returns an error, then you cannot install the notification request in the notification queue. In that case, your application should wait for the user to switch it to the foreground before doing further processing. While waiting for a resume event, your application should take care of other events, such as updates. Note, however, thatNMInstall
fails only if it is passed invalid information, namely, the wrong value forqType
.You can install notification requests at any time, even when the system is executing
'INIT'
resources as part of the system startup sequence. If you need to notify the user of some important occurrence during the execution of your'INIT'
resource, use the Notification Manager to install a request in the notification queue. The system notifies the user after the startup process completes, that is, when the normal event mechanism begins. This saves you from having to interrupt the system startup sequence with dialog or alert boxes and results in a cleaner and more uniform startup appearance.