Method MIMEContent():attachAlternative() Professional

Attach MIMEContent object as alternative content

Syntax
:attachAlternative( <oMIMEContent> ) --> lSuccess
Parameters
<oMIMEContent>
<oMIMEContent> is an object of the class MIMEContent or an object of a class that is derived from MIMEContent.
Return

The method :attachAlternative() returns .T. (true), if the object that is passed as a parameter was successfully attached. In case of an error, .F. (false) is returned.

Description

In order to attach an object of class MIMEContent to another object of the same class, :attachAlternative() can be used. Calling this method automatically transforms a single-part content to a multi-part content, if required.

With :attachAlternative(), it is possible to compose e-mails with alternative content. When sending html e-mails, for example, a text version of the html content can be attached using this method. Thus, the e-mail can also be viewed by clients that cannot display html pages. Please refer to the sample section of the MIMEMessageclass function for an example.

Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.