Copy link to clipboard
Copied
I have been searching for days and trying numerous formulas found on this community but can't seem to get the custom calculation script to work. Any help is greatly appreciated.
Here is the formula in Excel. =if(Amount1>0,Type,"")
In the Type field on the bottom, I am trying to say that if the amount is greater than 0 (where 300 is) then fill in the Type from the above field that I have already entered that into.
This is what it should look like when the formula works in Excel. Because I input JE16 in the top field, when I input the amounts in those fields below, the type JE16 shows in the first field to the left.
I hope this makes sense and thank you in advance for any help.
Copy link to clipboard
Copied
if (Number(this.getField("Amount1").valueAsString)>0) event.value = this.getField("Type").valueAsString;
else event.value = "";
Copy link to clipboard
Copied
I can't thank you enough!!!
I was trying to use that same formula to fill in a field with a letter but only if again the amount > 0. But there is nothing that it is pulling from so I'm not quite sure how to replace the "Type" with just the letter W. Thank you again.
Copy link to clipboard
Copied
Replace:
this.getField("Type").valueAsString;
With
"W";