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

how to set dynamically text field ?

Community Beginner ,
May 24, 2018 May 24, 2018

I create an interactive pdf in which I have several tables. one field that I fill in with a text field is in every table.

so I want that after entering the text in this field in one table it was available in this field in each table - How to do it dynamically?

TOPICS
PDF forms
2.9K
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
LEGEND ,
May 24, 2018 May 24, 2018

You either give the fields the same name or you use JavaScript to fill the other form fields from the source field.

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 Beginner ,
May 26, 2018 May 26, 2018

thank you very much

I set the same name for field and it works.

but i want to use JavaScript - How can I do it using java script?

what example script might be in this case?

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
LEGEND ,
May 26, 2018 May 26, 2018

For the "on blur" action for the first field enter the following JavaScript:

var cOtherField = "Other Field Name";

var oField = this.getField(cOtherField);

if(oField == null) {

app.alert("Error accessing field " + cOtherField, 1, 0, "Field Access Error");

}

if(oField != null) {

oField.value = event.value;

}

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 Beginner ,
May 26, 2018 May 26, 2018

ok,thank you very much

but where to paste this script? cOtherField is to be assigned a name in the name text field

you will describe briefly where exactly to set this script? or some tutorial you send?

best regards

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 Beginner ,
May 27, 2018 May 27, 2018
LATEST

yes, but this script only works if all text field - to which I want the text to be typed to be assigned the same name as text field first - in which I write the script, or how text field have the same name as assigned in var cOtherField.

and I want these text fields to be 5 and differ by name. how to change the script?

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