Skip to main content
New Participant
October 10, 2018
Question

How to send an email using mailDoc()?

  • October 10, 2018
  • 1 reply
  • 4709 views

I have a form that I need to send via email when a button is clicked.  So, using the "Mouse Up" trigger I entered a "Run a JavaScript" action.  Here's the code I entered into the "Create and Edit JavaScripts" box for the action:

//always send the email to HR

var cToEm = "me@mydomain.org"

// Get the employee's email address

var cEmpEm = this.getField("EmployeeEmail").value;

// Get the manager's email address

var cMgrEm = this.getField("ManagerEmail").value;

// Combine the two for the cc

var cCEm = cEmpEm + ";" + cMgrEm;

// Set the subject and body text for the email message

var cSubLine = "Catastrophe Timesheet for " + this.getField("NAME").value;

var cBody = "Please find attached document for " + this.getField("NAME").value.

// Send the entire PDF as a file attachment on an email

this.mailDoc({

bUI: true,

cTo: cToEm ,

cCc: cCEm ,

cSubject: cSubLine,

cMsg: cBody

});

But the emails aren't being sent.  What am I missing?

This topic has been closed for replies.

1 reply

New Participant
October 10, 2018

I failed to mention that I'm using Adobe Acrobat Pro DC on a Windows 10 PC.

try67
Community Expert
October 11, 2018

Check your Drafts folder...

On 10 October 2018 at 18:52, jeraldf7147659 <forums_noreply@adobe.com>