How to auto-'bring up' dropbox boxes based on previous dropdown selections

Dropdown box [Type] has a few options including ‘Loan’. When ‘Loan’ is selected, I want to have a new dropdown box [Loan Spread] that appears which requires a selection option for ‘Fall semester only’, ‘Spring semester only’, or ‘Fall semester + Spring semester’.
Then, I would like to have a final dropdown box [Estimated Loan Amount], which a number is then entered.
Finally, in each Text Field box (Fall Semester, Spring Semester) I then need to divide the [Estimated Loan Amount] by the number of semesters selected per the [Loan Spread] dropdown box.

Example: Student selects LOAN, then a pop-up dropdown box appears [Loan Spread] and the student then selects ‘Fall Semester + Spring Semester’ (which equates to 2 semesters), another pop-up dropdown box appears [Estimated Loan Amount] and the student enters $5000.00, and finally, the FALL SEMESTER Text Field and SPRING SEMESTER Text Field each auto-populate a $2500.00 value….{$5000.00 divided by 2 semesters = $2500.00}.

I don’t expect anyone to work this entire formula out but if I could get some basic tips on how to setup each of these steps, I would be greatly appreciative.


John Forest


Voted Best Answer

Step 1:

Select "commit selected values immediately" in the options tab of the "Type" field and enter the following custom validation script:

  if(event.value=="Loan")
    {
    this.getField("Loan Spread").display=display.visible;
    }
    else
    {
    this.getField("Loan Spread").display=display.hidden;
    }

The script above will show/hide the Loan Spread field dependent on the selection.

Step 2:

Select "commit selected values immediately" in the options tab of the "Loan Spread" field.

Step 3:

Make sure the selections in the "Estimated Loan Amount" drop down are numbers only (no currency symbols or commas - you can format the field as a number with a currency symbol after if you want), and select "commit selected values immediately" in the options tab.

Step 4:

Enter the following custom calculation script in the "FALL SEMESTER" text field:

var tp=this.getField("Type").value;
if(tp=="Fall semester only")
{event.value=this.getField("ESTIMATED LOAN AMOUNT").value}
else if(tp=="Fall semester + Spring semester")
{event.value=this.getField("ESTIMATED LOAN AMOUNT").value * .5}
else{even.value=0}

and enter the following custom calculation script in the "SPRING SEMESTER" text field:

var tp=this.getField("Type").value;
    if(tp=="Spring semester only")
    {event.value=this.getField("ESTIMATED LOAN AMOUNT").value}
    else if(tp=="Fall semester + Spring semester")
    {event.value=this.getField("ESTIMATED LOAN AMOUNT").value * .5}
    else{even.value=0}
________________________________________________________________________________________________________________ www.PDFAutomationStation.com

IMAGE ALT TEXT IMAGE ALT TEXT IMAGE ALT TEXT

_________________________________________________________________________________________________________________


By David Dagley   


Please specify a reason: