• Resolved stephenboluwatife

    (@stephenboluwatife)


    How can I set the amount for 3 dropdrown for example I create 3 dropdrown with different item/text in it drop-down 1 if user click on USA as the item in it and drop down 2 a user click on phone and the 3 dropdrown the user click on no sim how can I set it that all the three dropdown will calutate it all the amount I put in each one. Please note that each dropdown have 3 layers so the amount will be different. I hope you understand my words what I mean is that how can I have the total of the 3 dropdrown in the form

Viewing 1 replies (of 1 total)
  • Plugin Author codepeople

    (@codepeople)

    Hello @stephenboluwatife

    My apologies for the delay in responding to your question. I did not receive the WordPress notification.

    I’m sorry, I don’t understand your question. However, you can use conditional statements with the equations.

    For example, assuming you have three dropdown fields, fieldname1, fieldname2, and fieldname3.

    fieldname1 with choices A, B, and C
    fieldname2 with choices D and E
    fieldname3 with choices F, G, and H

    If you want to return a result based on the values combinations, the equation could be implemented as follows:

    (function(){
    	var f1 = fieldname1, f2 = fieldname2, f3 = fieldname3;
    	
    	if(AND(f1 == 'A', f2 == 'D', f3 == 'F')) return 1;
    	if(AND(f1 == 'B', f2 == 'D', f3 == 'F')) return 2;
    	if(AND(f1 == 'C', f2 == 'D', f3 == 'F')) return 3;
    	/* The other conditional statements here */
    })()

    Best regards.

Viewing 1 replies (of 1 total)

The topic ‘Drop-down calulate’ is closed to new replies.