What do the email object methods CreateForward and CreateReply exactly do?
The CreateReply and CreateForward methods return a new email object that is a pre-constructed reply or forward for the calling email object. For example:
CkEmail *reply = emailObject.CreateReply();or
Chilkat.Email forward = emailObject.CreateForward();
Specifically, each method does the following:
CreateReply: The reply email is equal to the original email with the following changes:
1) The contents of the Subject header field is prepended with "RE: "
2) The plain-text body is prepended with:
-----Original Message----- From: <from address> Sent: <original email date header field contents> To: <list of TO email addresses> CC: <list of CC email addresses> (This line may not be present) Subject: <original subject>3) If an HTML body exists, the same information is prepended to the HTML body in a very simple way. The information is prepended before the opening "html" tag, if one exists, because email clients generally display it correctly.
CreateForward: The forward email is equal to the original email with the following changes:
1) The Subject header is prepended with "FW: "
2) The plain-text and HTML bodies are modified in the same way as for CreateReply.
3) The TO and CC headers are cleared.
4) The various headers are removed just as in CreateReply.
5) The Date, Message-ID, and X-Priority are initialized just as in CreateReply.
Note: CreateReply and CreateForward are very simple methods to possibly make it quick and easy to create a reply or forward from an existing email. The behavior of these methods will not suit all possible needs, and there is nothing these methods do that cannot be duplicated via the email object (and MIME object) API's provided by Chilkat. If more sophisticated behavior is desired, then one should write application code that uses the functionality provided by the Chilkat email class, or potentially even the lower-level Chilkat MIME functionality, to generate the desired reply or forward.
Chilkat will not be changing the behavior of these methods to anything more sophisticated. In fact, it was probably a mistake to add these methods to the API in the first place, due to the simple fact that one set of behaviors will never satisfy the needs of all.