I have the code below for my "Send eMail" button. It works, but I would like to add a Cc:, Bcc, and Introduction. I would also like to add a hard-coded email address to the beginning of the "To:"
Why can't I just change
oEnvelope.To = rgRecipients.join(" ;");
to
oEnvelope.Cc = rgRecipients.join(" ;");
What is the secret to making this work?
----------------------------------------
function SendEmailBtn::OnClick(oEvent)
{
createEmail();
}
function createEmail()
{
var xmlContributors = XDocument.DOM.selectNodes("/iss:issue/iss:contributors/iss:contributor");
var xmlContributor;
var xmlTitle = XDocument.DOM.selectSingleNode("/iss:issue/iss:title");
var rgRecipients = new Array();
while (xmlContributor = xmlContributors.nextNode())
rgRecipients.push(getNodeValue(xmlContributor.selectSingleNode("iss:emailAddressPrimary")));
try
{
var oEnvelope = XDocument.View.Window.MailEnvelope;
oEnvelope.To = rgRecipients.join(" ;");
oEnvelope.Subject = getNodeValue(xmlTitle);
oEnvelope.Visible = true;
}
catch (ex)
{
XDocument.UI.Alert(ex.description);
}
}