Skip to main content
Participant
October 28, 2020
Answered

Change fields based on selection in drop down list

  • October 28, 2020
  • 2 replies
  • 6228 views

Hi there

 

I am designing a form in Acrobat Pro DC with the intention of being able to use the same form for a few different scenarios. So for example if "Delivery Note"is selected in the dropdown, a table will display providing options for "quantity", "item code" and "item description". (It's ok if this table shows form the beginning). 

 

My real question is that I would like to use the same form for "Demo Loans" but when this is selected from the dropdown I would like Check Boxes to be added next to each line item in the table that can be checked once the items are returned. 

 

Is it possible to only have the check boxes appear when the "Demo Loan" option is selected form the dropdown? 

 

Thanks for any help.  

Correct answer Nesa Nurani

You could use code like this in dropdown field "Custom Calculation Script" or "Custom Validation Script":

this.getField("Check Box2").display = event.value == "Demo Loan" ? display.visible : display.hidden
this.getField("Check Box3").display = event.value == "Demo Loan" ? display.visible : display.hidden
this.getField("Check Box4").display = event.value == "Demo Loan" ? display.visible : display.hidden;

Of course you  change field names and add more checkboxes if needed.

2 replies

Participant
June 2, 2025

I am trying to create a form that text boxes change to different values, when an item is selected from a drop down list. Is this possible

Nesa Nurani
Community Expert
Nesa NuraniCommunity ExpertCorrect answer
Community Expert
October 28, 2020

You could use code like this in dropdown field "Custom Calculation Script" or "Custom Validation Script":

this.getField("Check Box2").display = event.value == "Demo Loan" ? display.visible : display.hidden
this.getField("Check Box3").display = event.value == "Demo Loan" ? display.visible : display.hidden
this.getField("Check Box4").display = event.value == "Demo Loan" ? display.visible : display.hidden;

Of course you  change field names and add more checkboxes if needed.

Participant
October 29, 2020

Awesome thank you. That works beautifully!