I'm using this script (see below) in a custom button in the click event floating above the event.target.mailDoc function and it's working great to validate the input of fields and a check box. Does anyone know how to get else if(FirstName.rawValue=="" || FirstName.rawValue == null) to validate a radio buttons and a drop down menu? I didn't see any documentation on the process. Thanks, Brennan.
if(LastName.rawValue=="" || LastName.rawValue == null) {
xfa.host.messageBox("Please enter the employee's last name.");
}
else if(FirstName.rawValue=="" || FirstName.rawValue == null) {
xfa.host.messageBox("Please enter the employee's first name.");
}
else if(IAgree.rawValue == 0) {
xfa.host.messageBox("Please agree to the terms.");
}
else {
event.target.mailDoc({bUI:false, cTo:"umcdoittigerlinkrequests [at] missouri [dot] edu", cCc:SignatoryEmail.rawValue, cSubject:"Long-distance or calling card contract request/change/cancel submitted to the Division of Information Technology", cMsg:""+ContactName.rawValue+" submitted an order to request/change/cancel long-distance or calling card service from the Division of Information Technology for "+FirstName.rawValue+" "+LastName.rawValue+", using the MoCode:"+MoCode.rawValue+". Please open the attached PDF file and review the request in Adobe Acrobat. If you did not approve this request or if you think the order is not accurate, please notify the Division of Information Technology front desk by calling (573)882-2000."});
}
Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script