Implementing the PreprocessMessage Function for Preprocessors

The MAPI spooler calls the PreprocessMessage function for messages that meet the preprocessor's criteria for MAPIUID or address type. PreprocessMessage can do several things with the input message:

If multiple message preprocessors are being used, the individual PreprocessMessage functions are called in the same order as the transports. This order can be modified programmatically if your preprocessor needs to be called at some specific point in the transport order. See IMAPISession::AdminServices, IMsgServiceAdmin::MsgServiceTransportOrder and IXPLogon::AddressTypes for details.