• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
1

Javascript function to move form data down to insert a text field on radio button mouse up

New Here ,
Apr 17, 2024 Apr 17, 2024

Copy link to clipboard

Copied

Afternoon all. I am trying to create a checklist style form with (3) button radio group labeled (yes, no, and N/A) associated with each checklist data line. Upon clicking the "yes" radio button, a text field would appear, and push the rest of the checklist down to accomodate. A click to either of the other radio buttons would remove the text box and shift the checklist back to its original position.

 

The purpose is to keep the form as small as possible but allow for data entry if needed.

 

Does this functionality exist? or do i need to rethink my process?

TOPICS
Create PDFs , JavaScript , PDF , PDF forms

Views

89

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 17, 2024 Apr 17, 2024

Copy link to clipboard

Copied

There nothing built-in to PDF form for this behavior, but it can be done with a script, with limitations.  This type of programming is non-trivial and it does not change the size of the form. It would be impractical to change the positions of fields and text below the checklist. In fact, the most resonable design would be to make the checklist a fixed size. The script would simply move data around so all the filled lines are kept together. 

 

This type of fully dynamic form behavior (where lines are added and removed, and content below the checklist is move up or down) can be created in an AEM form. But not a true PDF form. 

 

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

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 17, 2024 Apr 17, 2024

Copy link to clipboard

Copied

LATEST

Thank you Thom, I will keep the actual checklist data static, and create a text field on a second page taht becomes visable or hiden upon mouse up for each checklist item. Thank you again. 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines