Skip to main content
Participant
September 12, 2016
Answered

CREATE HYPERLINK TO AN EMAIL ADDRESS FROM A BUTTON

  • September 12, 2016
  • 1 reply
  • 1089 views

I need your help please.

I have created a 'Email us'  button on my PDF.  When people click on this I want them to be redirected to their email with my email address already in the 'To' area.

I am using the latest Acrobat DC Pro version (free trial) and there is no option to create an email link.  I do not want to write my full email address on the page as I want them to simply click the 'Email us' button.

Can you help with this please?

Many thanks!

This topic has been closed for replies.
Correct answer Karl Heinz Kremer

Add a button to your document and select to execute a "Run a JavaScript" action and use the Doc.mailDoc() method. You can find out more about this method in the API documentation: Acrobat DC SDK Documentation - Doc.mailDoc()

Chances are that something like this (modified version of the code in the documentation) will work:

this.mailDoc({

    cTo: "apstory@example.com",

    cCc: "dpsmith@example.com",
    cSubject: "The Latest News",

    cMsg: "A.P., attached is my latest news story in PDF."

  });

1 reply

Karl Heinz  Kremer
Community Expert
Karl Heinz KremerCommunity ExpertCorrect answer
Community Expert
September 12, 2016

Add a button to your document and select to execute a "Run a JavaScript" action and use the Doc.mailDoc() method. You can find out more about this method in the API documentation: Acrobat DC SDK Documentation - Doc.mailDoc()

Chances are that something like this (modified version of the code in the documentation) will work:

this.mailDoc({

    cTo: "apstory@example.com",

    cCc: "dpsmith@example.com",
    cSubject: "The Latest News",

    cMsg: "A.P., attached is my latest news story in PDF."

  });

try67
Community Expert
Community Expert
September 12, 2016

The name of the second parameter should be "cCc"...

Karl Heinz  Kremer
Community Expert
Community Expert
September 12, 2016

Thanks for proof reading I should know by now to not trust the samples in the API documentation...