auto popopulate to text fields from a check box

Contributor ,
Aug 19, 2018

Copy link to clipboard

Copied

I am trying to figure out how to do this one last task for my document but I'm a little baffled being new to JS, but I have mastered how to auto populate a text field from a drop down box!  Yeah!!

Now I just need to figure out how to auto populate to my text fields from a check box, then I'll be done woo hoo

When the user ticks a check box (named 'Check box Sweeper 1') I would like the number '2' to auto populate to a text field named 'SSPHR1'.

I will have 12 check boxes named differently that will need to do the same thing...

When the user ticks the next check box (named 'Check box Sweeper 2') the number '2' will auto populate to the text field named 'SSPHR2 etc

I'm pretty sure I have to put the script in the 'Custom calculation script' in the 'SSPHR1', 'SSPHR2' etc text fields, but I'm not sure the script I would use.  Also, would I need to change anything in the Check box Sweeper fields?

Thank you!!

TOPICS
Acrobat SDK and JavaScript

Views

94

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

auto popopulate to text fields from a check box

Contributor ,
Aug 19, 2018

Copy link to clipboard

Copied

I am trying to figure out how to do this one last task for my document but I'm a little baffled being new to JS, but I have mastered how to auto populate a text field from a drop down box!  Yeah!!

Now I just need to figure out how to auto populate to my text fields from a check box, then I'll be done woo hoo

When the user ticks a check box (named 'Check box Sweeper 1') I would like the number '2' to auto populate to a text field named 'SSPHR1'.

I will have 12 check boxes named differently that will need to do the same thing...

When the user ticks the next check box (named 'Check box Sweeper 2') the number '2' will auto populate to the text field named 'SSPHR2 etc

I'm pretty sure I have to put the script in the 'Custom calculation script' in the 'SSPHR1', 'SSPHR2' etc text fields, but I'm not sure the script I would use.  Also, would I need to change anything in the Check box Sweeper fields?

Thank you!!

TOPICS
Acrobat SDK and JavaScript

Views

95

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
Aug 19, 2018 0
Contributor ,
Aug 19, 2018

Copy link to clipboard

Copied

I did it!

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...
Aug 19, 2018 0