Make a calculation based on field choice value

cicgordy
Tera Guru

Hi all,

Wondering if you can help me with this.

I created a demand risk assessment section/tab and added some fields. Depending of what I chose (Yes/no OR High/medium/low), I want to make a sum of the values I have given to the choices (I have explained the points into the image below), and by clicking the UI action "Demand risk calculation" the sum of all the points should automatically populate in the read only "Risk score" field at bottom, and also populate High/medium/high in the read only  "Risk level" field (if sum is 2 = Low, if sum is 3 to 9 = Medium and if sum is 10+ = High).

 

 

Many Thanks

 

1 ACCEPTED SOLUTION

@cicgordy 

 

Please find the screenshot below:

PrinceArora_0-1683640705733.png

PrinceArora_1-1683640740340.png

 

Syntax is not correct.

 

 

 

View solution in original post

12 REPLIES 12

@Prince Arora Yes, values are right, in fact the alert message shows the correct the sum.

I created these fields, they aren't OOB.

 

@cicgordy 

 

 

Can you please copy your code here, might be some small issue let me check on it

Also whats the backend value of Risk Level please make sure you are using the backend name of choices.

 

If my answer solved your issue, please mark my answer as Correct & 👍Helpful based on the Impact.

 

 

 

Actually it worked now, you were right, I messed up with values.

Thank you so much 🙂