adobe form help -currently using Acrobat XI

Community Beginner ,
Jul 11, 2018

Copy link to clipboard

Copied

Please help and would be greatly appreciated. 

I have a form that I input a value from 1 to 9.  value input can be 1, 1-2, 2, 2-3, 3, 3-4, 4, so on up to 8-9, 9.

when the value is inputted (from 1 to 9) , can I make a form that automatically puts a check mark on the appropriate check box?  I have three check mark box which are mild, moderate and severe.

to clarify here is example:

in the text box type in 3 and the mild check box will get checked automatically.  if value is updated to 8-9 "severe" check mark box will be checked.

THANK YOU SO MUCH for your help.

Most Valuable Participant
Correct answer by try67 | Most Valuable Participant

Use this code as the custom validation script of "VAS1":

var vas = event.value;

var cb = this.getField("Check box 1");

if (vas=="1" || vas=="1-2" || vas=="2" || vas=="2-3" || vas=="3") cb.value = "mild";

else if (vas=="3-4" || vas=="4" || vas=="4-5" || vas=="5" || vas=="5-6" || vas=="6") cb.value = "moderate";

else if (vas=="6-7" || vas=="7" || vas=="7-8" || vas=="8" || vas=="8-9" || vas=="9") cb.value = "severe";

else cb.value = "Off";

TOPICS
Acrobat SDK and JavaScript, Windows

Views

134

Likes

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

adobe form help -currently using Acrobat XI

Community Beginner ,
Jul 11, 2018

Copy link to clipboard

Copied

Please help and would be greatly appreciated. 

I have a form that I input a value from 1 to 9.  value input can be 1, 1-2, 2, 2-3, 3, 3-4, 4, so on up to 8-9, 9.

when the value is inputted (from 1 to 9) , can I make a form that automatically puts a check mark on the appropriate check box?  I have three check mark box which are mild, moderate and severe.

to clarify here is example:

in the text box type in 3 and the mild check box will get checked automatically.  if value is updated to 8-9 "severe" check mark box will be checked.

THANK YOU SO MUCH for your help.

Most Valuable Participant
Correct answer by try67 | Most Valuable Participant

Use this code as the custom validation script of "VAS1":

var vas = event.value;

var cb = this.getField("Check box 1");

if (vas=="1" || vas=="1-2" || vas=="2" || vas=="2-3" || vas=="3") cb.value = "mild";

else if (vas=="3-4" || vas=="4" || vas=="4-5" || vas=="5" || vas=="5-6" || vas=="6") cb.value = "moderate";

else if (vas=="6-7" || vas=="7" || vas=="7-8" || vas=="8" || vas=="8-9" || vas=="9") cb.value = "severe";

else cb.value = "Off";

TOPICS
Acrobat SDK and JavaScript, Windows

Views

135

Likes

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
Jul 11, 2018 0
Most Valuable Participant ,
Jul 11, 2018

Copy link to clipboard

Copied

Which values correspond with each check-box?

What are the names (and export values) of the fields involved?

Likes

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
Reply
Loading...
Jul 11, 2018 0
Community Beginner ,
Jul 11, 2018

Copy link to clipboard

Copied

Mild check box will be values of 1; 1-2; 2; 2-3; 3

Field Name: Check box 1; export value mild

Moderate check box will be values of 3-4; 4; 4-5; 5; 5-6; 6

Field Name: Check box 1; export value moderate

And severe check box will be vlaues of 6-7; 7; 7-8; 8; 8-9; 9.

Field Name: Check box 1; export value severe

Name of text box getting the value from1 to 9 is VAS1.

THANK YOU. So much for your help!

Likes

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
Reply
Loading...
Jul 11, 2018 0
Most Valuable Participant ,
Jul 11, 2018

Copy link to clipboard

Copied

Use this code as the custom validation script of "VAS1":

var vas = event.value;

var cb = this.getField("Check box 1");

if (vas=="1" || vas=="1-2" || vas=="2" || vas=="2-3" || vas=="3") cb.value = "mild";

else if (vas=="3-4" || vas=="4" || vas=="4-5" || vas=="5" || vas=="5-6" || vas=="6") cb.value = "moderate";

else if (vas=="6-7" || vas=="7" || vas=="7-8" || vas=="8" || vas=="8-9" || vas=="9") cb.value = "severe";

else cb.value = "Off";

Likes

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
Reply
Loading...
Jul 11, 2018 0
ytk1978 LATEST
Community Beginner ,
Jul 11, 2018

Copy link to clipboard

Copied

THANK YOU SO MUCH!! and have a great evening.

If you ever visit Phila, PA, (I work at the Phila airport (PHL))  please contact me!  I would like to show my appriciation over coffee, lunch, and/or dinner.

once again, THANK YOU!

Likes

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
Reply
Loading...
Jul 11, 2018 0