IR Framework

ActiveDocument.createEmail Function

Creates an e-mail message containing the url to the current query document.
[ActiveDocument.]createEmail ([To, [Subject, [Message, [Attachments, [IncludeLink]]]]])

Arguments

To
Optional. An array of strings containing valid e-mail addresses. If this argument is not an array, it is ignored. Any non-string value in this array is ignored. The default value is blank.


Subject
Optional. A string value to populate the subject line of the e-mail. The default value is "Link to Report".


Message
Optional. A string value to replace the generic message before the url. The default is "Please follow this link to the report:\n\n".


Attachments
Optional. An array of strings containing valid paths to files to attach to the message. If this argument is not an array, it is ignored. Any non-string value in this array is ignored. The default value is blank (no attachments).


IncludeLink
Optional. Boolean value indicating whether or not to include in the message body a hyperlink to the current document.




Remarks

The createEmail function only works properly when viewing a query document that was opened from within the Workspace. If the function is used from a document opened from a local or network drive, the url is incorrect.

The following example uses createEmail to create an e-mail with a custom message addressed to three people:

ActiveDocument.createEmail(["John.Doe@gmail.com","SchmoeJ@mail.ahoo.com"], undefined, "As we discussed...\n\n");


Requirements

Microsoft Outlook