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

require entry in field before allowing form to print

Rachel
Registered: Jul 9 2008
Posts: 14

Hello,

Is there a way to require an entry in a field before allowing the form to be printed?

I have a form that will work for several different functions, but only if one field is changed each different function. I would like to make it mandatory to complete that field before printing as the form will not be valid without that entry.

Thanks!

Rachel

My Product Information:
LiveCycle Designer, Windows
thomp
Expert
Registered: Feb 15 2006
Posts: 4411
Unfortunately there is no automatic way to do this. You can create a custom print button on your form that runs code to check the required fields and only prints if everything is filled out.

You can also use the "PrePrint" event to do this checking, but it can't be used to stop the printing. About the best you can do with this event is to display a popup message warning the user that the form is invalid.

Thom Parker
The source for PDF Scripting Info
[url=http://www.pdfScripting.com]pdfscripting.com[/url]

The Acrobat JavaScript Reference, Use it Early and Often
[url=http://www.adobe.com/devnet/acrobat/]http://www.adobe.com/devnet/acrobat/[/url]

Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script

scottsheck
Registered: May 3 2007
Posts: 138
Rachel,

You could try entering a script in the the click event of a regular button, which has an IF statement that checks if the field is filled in, and if so, call the xfa.host.print() function.