Support » Plugin: Calculated Fields Form » Set Equation

• Resolved relisys

(@relisys)

ok, hi nice plugin. My question is, i am trying to calculate from for example if someone entered the value 80 in the field, the output would be = 4… so it works out as 20 = 1, 40 = 2 60 = 3

could you help me set the Set Equation, for this.

Viewing 6 replies - 1 through 6 (of 6 total)
• Plugin Author codepeople

(@codepeople)

Hello @relisys,

The process is really simple, you are dividing the number by 20.

For example, assuming the number field in the form is fieldname1, the equation would be:

fieldname1/20

If you need only the whole part of division:

FLOOR(fieldname1/20)

If you want round the result to the nearest integer number:

ROUND(fieldname1/20)

Best regards.

relisys

(@relisys)

this is the one I got, (fieldname2 fieldname1/20) thank you for confirming, is there any way of setting the results of 1, 1.5, 2, 2.5 so on and so forth.

Plugin Author codepeople

(@codepeople)

Hello,

The equation (fieldname2 fieldname1/20) is incorrect, it should be simply fieldname1/20

Now, if you want to round the results as 0, 0.5, 1, 1.5, 2, 2.5, … It is simple mathematics

``````
ROUND(fieldname1/20/0.5)*0.5
``````

and that’s all.
Best regards.

relisys

(@relisys)

oh, no they enter a value in fieldname2 and the output is in fieldname1/20) I get the correct results, however, I do it.

and next mathematics you provide is fantastic, this is what I wanted. thank you again.

Plugin Author codepeople

(@codepeople)

Hello @relisys,

If you need additional help to implement your project, I can offer you a custom coding service from my private website:

https://cff.dwbooster.com/customization

Best regards.

relisys

(@relisys)

ok thank you, I will keep you in mind if I come across needing this service.

Viewing 6 replies - 1 through 6 (of 6 total)
• You must be logged in to reply to this topic.