IConverterSession::SetAdrBook

Last modified: July 23, 2011

Applies to: Outlook

Specifies an optional MAPI Address Book that the MAPI to MIME converter uses to resolve ambiguous addresses when converting a MAPI message to a MIME stream.

HRESULT IConverterSession::SetAdrBook( 
LPADRBOOK pab); 

pab

[in] Pointer to an IAddrBook : IMAPIProp interface to be used in the MAPI to MIME conversion. Set this parameter to null when you no longer need the Address Book; this releases the interface and resets the converter to not using any Address Book.

S_OK

The function call is successful.

Converting a MAPI message to MIME stream generally does not require logging on to a MAPI profile. However, specifying a MAPI Address Book for conversion requires logging on to a profile to obtain the Address Book.

For MFCMAPI sample code, see the following table.

File

Function

Comment

MapiMime.cpp

ImportEMLToIMessage

MFCMAPI uses MimeToMAPI to convert an EML file to a MAPI message.

MapiMime.cpp

ExportIMessageToEML

MFCMAPI uses MAPIToMIMEStm to convert a MAPI message to an EML file.

Show:
© 2014 Microsoft