PMDF Programmer's Reference Manual


Previous Contents Index

2.1.2 To:, Cc:, and Bcc: Addresses

The list of "To:", "Cc:" and "Bcc:" addresses to send a message to is built up, one address at a time, with item list entries. Each item list entry specifies the type of address ("To:", "Cc:", or "Bcc:") and a string containing the address. The type of address is denoted by the item code, PMDF_TO , PMDF_CC , or PMDF_BCC , associated with the item entry. PMDF_send will use this information to build the message's envelope "To:" address list and "To:", "Cc:", and "Bcc:" header lines.

To specify an envelope-only address which should not appear in the message header (i.e., an active transport address), use PMDF_ENV_TO , PMDF_ENV_CC , or PMDF_ENV_BCC , as appropriate.3 Likewise, to specify a header-only address which should not appear in the envelope (i.e., an inactive address), use PMDF_HDR_TO , PMDF_HDR_CC , or PMDF_HDR_BCC , as appropriate.

When one or more of the "To:", "Cc:", or "Bcc:" addresses is illegal, PMDF_send will not, by default, indicate which addresses were in error. By using the PMDF_ADDRESS_STATUS item code; however, this differentiation can be achieved. When this item code is used, the string containing each "To:", "Cc:", or "Bcc:" address passed in to PMDF_send must have a length of at least ALFA_SIZE bytes. On output, PMDF_send will overwrite each address with a status message (which includes the original address in the message). The item_length field associated with each address will contain the length of the returned message and an indication as to whether the address was legal or illegal. The magnitude of the value stored in the item_length field will give the length of the message; the sign of the value will indicate if it was legal (positive sign) or illegal (negative sign).

Note

3 While it is correct that PMDF currently does not distinguish between "To:", "Cc:", and "Bcc:" recipients in the envelope, distinct item codes are nonetheless provided for specifying envelope-only recipients. Use them as you see fit.


Previous Next Contents Index