These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Add subject to submit button LiveCycle

leenders
Registered: Oct 16 2007
Posts: 4

I would like to add a subject to a submit button I added to a form created with LiveCycle 8. This button must send the PDF form (so not only the xml data. That's why I can't use the email submit button.
Does someone have a solution for this?
 
Thanks!

My Product Information:
LiveCycle Designer, Windows
pddesigner
Registered: Jul 9 2006
Posts: 858
Try this solution:

This example demonstrates how to email a form to an address specified by the person filling the form.

Instructions

Add a Text Field (TextField1)

Add a button - (Button1) Not an email submit button.

preSubmit* - Script - click event of the email button

this.resolveNode("#event").submit.target = "mailto:" + TextField1.rawValue + "?
subject=email data

Note: Specify the button as a submit button before typing the preSubmit
event. The script will point to the first element specified for the
button.


validate* - Script - validate event for TextField1

var address = new RegExp();
address.compile("^[a-z0-9_\\-\\.]+\\@[a-z0-9_\\-\\.]+\\.[a-z]{2,3}$","i");
var result = address.test(this.rawValue);
if (result == true){
true;
} else {
false;
}

My favorite quote - "Success is the ability to go from one failure to another with no loss of enthusiasm.