Hello. I've research many hours and managed to piece together some working script for a Performance Review form. I'm using Live Cycle 11 and java script. if there is already an answer for this post please direct me to the URL. I understand scripting but don't use it enough to be proficient. So here we go....
1) the form consists of 12 categories - and each category has: a label, drop down, text and text field
2) The drop downs are identical rating choices numbered 0-5. i set 0= "(Choose One)"
3) If a user selects rating 2,3,or 4, the text field is optional
3) when a user selects 1 (unacceptable) or 5 (Excellent), the corresponding text field is set to mandatory with a message prompting for an explanation (i used the action builder for the message). in the script below "Relation" is the category - all drop downs have the same script syntax referencing the their category
Well, i figured out the second question, was straight forward. I just had to use the full path when referencing the objects. i.e. page1.field, page2.field etc. Then using the calculated average, display message describing the value range.
Still trying to figure out why the "error" value doesn't force the text field to be mandatory or required. the "error" value only highlights the field to be required.