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

Automatic realignment of text fields (possible with JavaScript)

New Here ,
Apr 22, 2021 Apr 22, 2021

Hello community,
I have different textfields and to keep the document clear I decided to install checkboxes on the first pages. If the user selects a checkbox, the related textfields disappears. I implemented that with the following Javascript:
if (this.getField("checkbox1").value=="Off")
this.getField("Textfield1").display=display.visible;
else
this.getField("Textfield1").display=display.hidden;
The goal is that the other text fields are moving upwards as soon as a text field disappeared. Is that possible? Is it maybe possible that elements align automatically? Or is it possible to implement that with another JavaScript?


Thanks in advance.

TOPICS
Create PDFs , How to , JavaScript
319
Translate
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 22, 2021 Apr 22, 2021
LATEST

You can move fields on the page by changing the value of their rect property.

Translate
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