Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Encodes the specified message body using Secure/Multipurpose Internet Mail Extensions (S/MIME).
Syntax
HRESULT EncodeBody(
[in] IMimeMessageTree pTree,
[in] HBODY hEncodeRoot,
[in] DWORD dwFlags
);
Parameters
-
pTree [in]
-
Type: IMimeMessageTree
Specifies a pointer to the IMimeMessageTree object that contains the body to encode.
-
hEncodeRoot [in]
-
Type: HBODY
Specifies the handle of the body to encode.
-
dwFlags [in]
-
Type: DWORD
Specifies a set of encode body flags (EBF_*) or security encoding flags (SEF_*). Do not overlap EBF_* and SEF_* flags.
-
EBF_RECURSE (0x00010000)
-
EBF_COMMITIFDIRTY (0x00020000)
-
EBF_MASK (0xffff0000)
-
SEF_ENCRYPTWITHNOSENDERCERT (0x00000001)
-
SEF_SENDERSCERTPROVIDED (0x00000002)
-
SEF_NOUI (0x00000004)
-
SEF_MASK (0x0000ffff)
-
Return value
Type: HRESULT
Returns one of the following values.
| Return code | Description |
|---|---|
|
Indicates success. |
|
Indicates that an unknown error has occurred. |
|
Indicates that pTree or hEncodeRoot is NULL. |
|
Indicates that the body is not encoded. |
|
Indicates that the message is an unsupported S/MIME class. |
|
Indicates that no certificates were found. |
|
Indicates that an attempt to allocate memory failed. |
|
Indicates that the body is already encoded with an unknown certificate. |
Remarks
S/MIME is the secure version of MIME.
Requirements
| Minimum supported client |
Windows XP [desktop apps only] |
| Minimum supported server |
Windows Server 2003 [desktop apps only] |
| Product |
Outlook Express 6.0 |
| Header |
|
| IDL |
|
| DLL |
|