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

how can I calculate a percentage of a field using forms in acrobat?

New Here ,
Jan 18, 2021 Jan 18, 2021

Copy link to clipboard

Copied

I have 2 forms. I need form 2 to be 3% of form 1. 

event.value = this.getfield(form1) * .03

how can I finish this custom calculation script so the if form 1 was 100, it would calculate 3?

*it will always be 3% so I don't want a field for that.

 

Moved from Using the Community (which is about the forums) to the correct forum... Mod
To find a forum for your program please start at https://community.adobe.com/

TOPICS
How to

Views

374

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 , Jan 18, 2021 Jan 18, 2021

Is the field name "form 1" or "form1"? Assuming it's the former, use this as the custom calculation script for "form 2":

event.value = Number(this.getField("form 1").valueAsString) * 0.03;

Votes

Translate

Translate
Community Expert ,
Jan 18, 2021 Jan 18, 2021

Copy link to clipboard

Copied

Is the field name "form 1" or "form1"? Assuming it's the former, use this as the custom calculation script for "form 2":

event.value = Number(this.getField("form 1").valueAsString) * 0.03;

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 ,
Jan 19, 2021 Jan 19, 2021

Copy link to clipboard

Copied

LATEST

Thank you so much!

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