Expand my Community achievements bar.

How do I add a CC in a "regular button" script

Avatar

Level 2

Hello, I have the below script, which works perfectly fine except that it doesn't read the cCC. Anyone know what I am doing wrong? Event type: Click Object type: Button with control type Regular var subject = CC_request.REQUEST.DD_tool.rawValue + " " + CC_request.REQUEST.GEN_document_number.rawValue + " " + CC_request.REQUEST.GEN_document_type.rawValue; var myDoc = event.target; try {     myDoc.mailDoc({         bUI: false,         cTo: 'nancy.caroline@gmail.com', // Replace with actual receiver mail address.         cCC: "nancy.caroline@gmail.com",         cSubject: subject,         cSubmitAs: "PDF"     }); } catch (e) {     // exception handling... } thanks in advance. Kr, Nancy

1 Reply

Avatar

Level 10

Hi,

try this script:

var subject = "Test E-Mail";

event.target.mailDoc({

  bUI: false,

  cTo: 'receiver1@domain.org',

  cCc: '',

  cBcc: 'receiver2@domain.org',

  cSubject: subject,

  cMsg: 'Test'

});