cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Nintex Newbie

Convert Alpha Dropdown Values to Numeric

Using Nintex Responsive Forms in Sharepoint Online. 

 

I have 10 Questions, all with the same dropdown values (N/A, Meets, Doesn't Meet).

 

At the end of the form, I would like to provide the User with a "Final Score."  Simply, if there are more "Meets" than "Doesn't Meets," then the final score would show "Meets."  Likewise, if there are more "Doesn't Meets" than "Meets," then the final would show "Doesn't Meet."

 

Is there a way to make that happen through Variables/Rules? 

 

Or would I convert each answer to a numeric value?  Meets = 2, N/A = 1, Doean't Meet = 0; and then if it's > 10 = Meets, and < 10 = Doesn't Meet. 

 

Either way, how would I go about doing so?  I can't seem to figure out how to convert the answers to numbers, nor can I think of rules/variables that work.

Labels: (1)
0 Kudos
Reply
3 Replies
Highlighted
Nintex Employee
Nintex Employee

Re: Convert Alpha Dropdown Values to Numeric

Hi,

 

I would approach this solution like this.

If they meet they get 1 point.  If they dont meet they get -1 point.  The end result will be a plus or a minus score and zero is a pass. If NA then no points.

 

For each choice control create a variable with a formula that calculates the point based on the choice.

I have named my choice controls A1 to A10 so first variable will look like.

If(equals(A1,"Meets"),1,If(equals(A1,"Doesnt Meet"), -1, 0))

Add a calculated control on the form that adds up the Variables (My varaiables are _A1 to _A10) and outputs Meets or Doesnt Meet based on the result.

If((_A1 +_A2 +_A3 +_A4 +_A5 +_A6 +_A7 +_A8 +_A9 +_A10 )<0,"Doesnt Meet","Meets")

Please find attached the POC responsive form.

I spent about an hour on this so please mark this post as the Accepeted Solution if it fulfills your needs.

 

0 Kudos
Reply
Highlighted
Nintex Newbie

Re: Convert Alpha Dropdown Values to Numeric

Thank you for the reply and the work involved.

In the Responsive Designer, I'm not able to use those functions.

Here is my Variable formula: If(equals([Form].[Greeting],"Met Criteria"),1,If(equals([Form].[Greeting],"Needs Improvement"), -1, 0))

And the errors:
Ln 1, Col 1: Function 'If' cannot be found.
Ln 1, Col 4: Function 'equals' cannot be found.
Ln 1, Col 71: Function 'If' cannot be found.
Ln 1, Col 74: Function 'equals' cannot be found.
Formula return type does not match type 'number'.
0 Kudos
Reply
Highlighted
Nintex Employee
Nintex Employee

Re: Convert Alpha Dropdown Values to Numeric

Sorry, you said Responsive forms not New Responsive forms.
Create your variables like:
ifElse([Form].[Choice1] == "Meets",1,ifElse([Form].[Choice1]=="Doesnt Meet",-1,0))

NewResFormVars.png

 

Create another variable that adds all the choice variables up

NewResFormVarstot.png

 

and then use a rule to populate the result field based on the total. ie is it less than zero.

NewResFormRule.png

 

see attached New Responsive form for a POC.

0 Kudos
Reply