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

Replace part of the fields name

Participant ,
Jul 24, 2017 Jul 24, 2017

hi, in my form, field names are like bellow..

primary-fn-lastname

primary-fn-firstname

primary-fn-middlename

I want to replace "primary" with "child-3". so new fields names should be like bellow. is this possible to do using javascripts??. thanks in advance.

child-3-fn-lastname

child-3-fn-firstname

child-3-fn-middlename

TOPICS
Acrobat SDK and JavaScript , Windows
387
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 ,
Jul 24, 2017 Jul 24, 2017

Want you create new form fields?

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
Participant ,
Jul 24, 2017 Jul 24, 2017

hi, thanks a lot for your reply. is that possible to send code to create new fields using new field names. don't worry about field formatting because there are no special formatting in my fields.. thanks..

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 ,
Jul 24, 2017 Jul 24, 2017
LATEST

Look at the method addField in the Acrobat JavaScript Reference.

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 ,
Jul 24, 2017 Jul 24, 2017

JS can't rename fields. It can only create new fields in the same location with the new name, and then delete the old ones.

In this process all of the Actions, Format, Validation, Calculation, Keystroke, etc. that are associated with the fields will be lost, though.

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