Generates delivery and nondelivery reports.
[in] A pointer to the message for which the report should be generated.
[in] A pointer to an ADRLIST structure that describes the recipients of the message pointed to by lpMessage.
The report was successfully generated.
The call succeeded overall, but there are no recipient options for this type of recipient. When this warning is returned, the call should be handled as successful. To test for this warning, use the HR_FAILED macro. For more information, see Using Macros for Error Handling.
You can call StatusRecips multiple times during the processing of a message. However, if you call StatusRecips for an open message, do your best to collect all delivery and nondelivery information for the message recipients and call StatusRecips for that recipient list. A single point of collection is important, because multiple StatusRecips calls for one recipient can result in multiple identical reports being sent.
Store properties that relate to message delivery or nondelivery in the ADRLIST structure indicated by the lpRecipList parameter. For a complete list of required and optional properties for delivery reports and nondelivery reports, see Required Report Message Properties and Optional Report Message Properties.
Allocate memory for the ADRLIST structure in lpRecipList by using the MAPIAllocateBuffer and MAPIAllocateMore functions. MAPI releases the memory by calling the MAPIFreeBuffer function only if StatusRecips succeeds.
For an overview of delivery and nondelivery reports, see MAPI Report Messages.