0
Community Beginner
,
/t5/acrobat-sdk-discussions/calculating-fields-with-if-else/td-p/8682227
Nov 01, 2016
Nov 01, 2016
Copy link to clipboard
Copied
Help! I am such a newbie and I have tried to utilize the other posts which were similar.
Here is the simple script.
var C5 = this.getField("C5").value
if(C5=0) {
event.value=0;
}else {
event.value=(1000/C5);
}
When I change the value in C5, nothing changes in the calculated field it just keep displaying 'Infinity'.
I am using acrobat for the form creation.
TOPICS
Acrobat SDK and JavaScript
,
Windows
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
1 Correct answer
Community Expert
,
Nov 01, 2016
Nov 01, 2016
Change:
if(C5=0) {
To:
if(C5==0) {
Community Expert
,
/t5/acrobat-sdk-discussions/calculating-fields-with-if-else/m-p/8682228#M37955
Nov 01, 2016
Nov 01, 2016
Copy link to clipboard
Copied
Change:
if(C5=0) {
To:
if(C5==0) {
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
davidm76220796
AUTHOR
Community Beginner
,
LATEST
/t5/acrobat-sdk-discussions/calculating-fields-with-if-else/m-p/8682229#M37956
Nov 01, 2016
Nov 01, 2016
Copy link to clipboard
Copied
OMG !!!
THANK YOU !!!
It works perfectly now!!
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more

