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

Check field equal a value once it is clicked

New Here ,
Sep 16, 2022 Sep 16, 2022

Copy link to clipboard

Copied

How can I make a check mark equal a number in a different field once its clicked?

 

TOPICS
How to

Views

402

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 1 Correct answer

Community Expert , Sep 16, 2022 Sep 16, 2022

As 'Mouse UP' action of that checkbox, add this script:

if(event.target.value != "Off")this.getField("Text1").value = 500;

Votes

Translate

Translate
Community Expert ,
Sep 16, 2022 Sep 16, 2022

Copy link to clipboard

Copied

This is a very vague explanation, can you please elaborate?

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
New Here ,
Sep 16, 2022 Sep 16, 2022

Copy link to clipboard

Copied

Daidrien26152486mi89_0-1663343510806.png

How can I make text1 equal 500 when the check mark is checked? 

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 ,
Sep 16, 2022 Sep 16, 2022

Copy link to clipboard

Copied

As 'Mouse UP' action of that checkbox, add this script:

if(event.target.value != "Off")this.getField("Text1").value = 500;

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
New Here ,
Sep 16, 2022 Sep 16, 2022

Copy link to clipboard

Copied

It worked. Thank you!!

 

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
New Here ,
Sep 16, 2022 Sep 16, 2022

Copy link to clipboard

Copied

How can I make it so it subtracts the value from the field if the checkmark is unselected? 

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 Beginner ,
Sep 16, 2022 Sep 16, 2022

Copy link to clipboard

Copied

LATEST

Update your code to this:

if(event.target.value != "Off")this.getField("Text1").value = 500;
else
this.getField("Text1").value = "";

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