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

Adobe form fill - make box 0 when no other number imputed

New Here ,
Jan 08, 2025 Jan 08, 2025

Currently have a file that has a 'calculation'. so the customer imputs a few numbers and at the end there a 'total savings'. My issue is that the 'total savings' is 2 fields subtracted from eachother + $15. so: (field 1 - field 2)+15. When the form is completly blank with no other numbers, the field is defaulting to show $15. Any way I can remove this so the calculation doesnt work unless the rest is filled out?

TOPICS
PDF , PDF forms
243
Translate
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
1 ACCEPTED SOLUTION
Community Expert ,
Jan 08, 2025 Jan 08, 2025

Use a custom calculation script:

var fld1=this.getField("field 1").value;

var fld2=this.getField("field 2").value;

if(!fld1 || !fld2)

{event.value=""}

else

{event.value=fld1 - fld2 + 15}

View solution in original post

Translate
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 ,
Jan 08, 2025 Jan 08, 2025

Use a custom calculation script:

var fld1=this.getField("field 1").value;

var fld2=this.getField("field 2").value;

if(!fld1 || !fld2)

{event.value=""}

else

{event.value=fld1 - fld2 + 15}

Translate
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 08, 2025 Jan 08, 2025
LATEST

thank u!!

Translate
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