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

Password protected form certain fields

Community Beginner ,
Nov 17, 2020 Nov 17, 2020

I only want to protect certain fields that I will fill in. The rest must be completed by the person receiving the form.

I have found an answer on this topic from: AkanchhaS but your link is going nowhere.
Could someone tell me if it really can be done. I would appreciate information or a link where you can find it.

TOPICS
Acrobat SDK and JavaScript
435
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 ,
Nov 17, 2020 Nov 17, 2020
LATEST

It can be done with a script, but it's not very secure.

Here's one possible way of doing it. Use this code as the custom Validation script of one such field:

 

event.rc = (app.response("Enter the password to edit this field:", "", "")=="1234");

 

If the user doesn't enter "1234" when exiting the field the value they entered into it will be replaced by the field's original value. If you want to apply the same code to multiple fields I would recommend putting it in a doc-level function and then just call it from the fields you want to protect. That will make editing the password or text of the message later on much easier.

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