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

Acrobat Pro How to set a check box with export value as read only depending on a drop down selection

Explorer ,
Aug 07, 2020 Aug 07, 2020

Copy link to clipboard

Copied

Hi there

I have a drop down field with 4 options (A, B, C, D). I have a another set of 3 checkboxes with different export values (X, Y and Z).

If options A, B and C are selected, I want the Checkbox with export value Z to be read only and change color to gray.

Is this possible?

Thanks in advance.

MG

TOPICS
PDF forms

Views

2.4K

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

correct answers 2 Correct answers

Explorer , Aug 09, 2020 Aug 09, 2020

Hi ls

Sorry I should have made myself clearer at the start. I don't usually use Export Value in check boxes unless I want it to work like a radio button. Yes, Nesa's code is perfect if I had different field names.

So how should I tweak the script?

Thanks

MM

 

Votes

Translate

Translate
Community Expert , Aug 09, 2020 Aug 09, 2020

Hi MM, I must admit if the checkboxes has same name I'm not sure how to adapt code to that(I'm, sure it's simple) but it's beyond my current level 😉 so if ls_rbls can help you he is more then welcome. In the meantime if you want to use my code above and you want checkboxes to act as radio buttons I have workaround for you, name your checkboxes different (example: X,Y,Z) and use this code as mouse up event of each checkbox just change their names if you want, for checkbox "X" use:

if(event.target

...

Votes

Translate

Translate
Community Expert ,
Aug 10, 2020 Aug 10, 2020

Copy link to clipboard

Copied

The readonly property is set at the field level, not the widget level, which means you can't set a single "widget" in a group of fields with the same name as read-only, while the others are not.

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
Community Expert ,
Aug 10, 2020 Aug 10, 2020

Copy link to clipboard

Copied

That would be a great feature if it was somehow implemented to work with both checkboxes and radio buttons.

 

 

Thank you as usual for your guidance!

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
Community Expert ,
Aug 10, 2020 Aug 10, 2020

Copy link to clipboard

Copied

It's possible to do it by creating fields with unique names and using a script to reset all other members of the "group" when one of them is ticked. It's actually not too complicated to do... And then you could enable/disable some of them without problems.

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
Explorer ,
Aug 11, 2020 Aug 11, 2020

Copy link to clipboard

Copied

LATEST

Thanks you everyone for your help on this.

MM

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