Partager via


IMAPISession::QueryDefaultMessageOpt

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Retrieves the message option properties for a particular address type.

HRESULT QueryDefaultMessageOpt(
  LPSTR lpszAdrType,
  ULONG ulFlags,
  ULONG FAR * lpcValues,
  LPSPropValue FAR * lppOptions
);

Parameters

  • lpszAdrType
    [in] A pointer to an address type. This string must be an ANSI string.

  • ulFlags
    [in] Reserved; must be NULL.

  • lpcValues
    [out] A pointer to a count of property values pointed to by the lppOptions parameter.

  • lppOptions
    [out] A pointer to a pointer to an array of SPropValue structures that describe message option properties.

Return Value

  • S_OK
    The message option properties were successfully returned.

Remarks

The IMAPISession::QueryDefaultMessageOpt method retrieves the one or more message option properties that a transport provider supports for the address type that the lpszAdrType parameter points to. Message option properties control a message's behavior after it is submitted to the transport provider; they are part of the message envelope, not its content.

The property value array that the lppOptions points to includes the property tags and values for each of the message option properties.

MFCMAPI Reference

For MFCMAPI sample code, see the following table.

File

Function

Comment

MainDlg.cpp

CMainDlg::OnQueryDefaultMessageOpt

MFCMAPI uses the IMAPISession::QueryDefaultMessageOpt method to obtain message option properties and display them in a dialog box.

See Also

Reference

SPropValue

IMAPISession : IUnknown

Concepts

MFCMAPI as a Code Sample