How to: Access a Message on an IMAP Store Without Downloading the Entire Message
|How to: Access a Message on an IMAP Store Without Downloading the Entire Message|
This topic shows a code sample in C++ that queries a message store for the IProxyStoreObject interface, and uses the returned pointer and the IProxyStoreObject::UnwrapNoRef function to obtain a pointer to an IMAP store object that has been unwrapped. Using this unwrapped store allows access to a message in its current state without invoking a download of the entire message.
Because UnwrapNoRef does not increment the reference count for this new pointer to the unwrapped store object, after successfully calling UnwrapNoRef, you must call IUnknown::AddRef to maintain the reference count.