Skip to main content
Participant
April 23, 2024
Question

How to populate text fields from multiple checkbox selections?

  • April 23, 2024
  • 1 reply
  • 245 views

I have 25 different checkboxes in my form. Based on the selections made (multiple allowed), I want the appropriate text fields to populate. Some of the text fields populated may repeat based on the combination of selections made. Is there a way to populate the text fields (minus any repeat text fields) based on multiple selections of the 25 checkboxes? The text fields are all pre-determined text. 

This topic has been closed for replies.

1 reply

Thom Parker
Community Expert
Community Expert
April 23, 2024

Yes, there are at least a couple of different ways. 

The most straight forward to use a calculation script on each text field to set it's own value:

Here are some articles that will help:

https://www.pdfscripting.com/public/Calculating-field-values-and-more.cfm

https://www.pdfscripting.com/public/Checkboxes-and-Radio-Buttons.cfm

https://www.pdfscripting.com/public/How-to-write-an-If-statement.cfm

 

 

Thom Parker - Software Developer at PDFScriptingUse the Acrobat JavaScript Reference early and often