Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript PDF this.submitForm Custom Subject Line

  • This topic is empty.
Viewing 1 post (of 1 total)
  • Author
    Posts
  • #255168

    Hi all,

    I am trying to execute a javascript in a PDF that will allow the form to be submitted via email with a subject line that will pull a value from a field in the form, with a click of a button. I am able to get the email portion to work, but I have not been able to customize the subject line to pull from the field. Below is the base script I am using to send the email without the customized subject line

    this.submitForm({
    
        cURL: "mailto:[email protected]?subject=TSC Form&body=",
    
        cSubmitAs: "PDF"
    
    });
    

    The field I am wanting to pull from is labeled: Name. Below was one of my attempts, all of which have not worked.

    Failed Script:

    this.submitForm({
    
        var Name = this.getField("Name").value;
    
            cURL: "mailto:[email protected]?subject=TSC Form (Name)&body= ) ",
    
            cSubmitAs: "PDF"
    
    });
    

    Can some one point me in the right direction?

Viewing 1 post (of 1 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.