Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
yzhang88
Contributor III
Contributor III

Select multiple values from listbox and then use match functions

Can I select multiple values from listbox and then use match function in expression? For example, I select 'Code' from the listbox with multiple values 'A' and 'B', and then in a chart expression, I want to use  =if(match(Code, 'A','B', 'C','D'), 1, 0). how to do this with multiple selections? I tried with single selection value, it returns 1, but multiple selections always returns 0.

1 Solution

Accepted Solutions
yzhang88
Contributor III
Contributor III
Author

figured out the solution, it returns the correct result.

=if( wildmatch ( GetFieldSelections (Code, ','), '*A*','*B*', '*C*','*D*'), 1, 0)

View solution in original post

3 Replies
Anil_Babu_Samineni

How about this?

If(GetPossibleCount(Code)>1, 1,0)

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
yzhang88
Contributor III
Contributor III
Author

Thank you for quick reply, while I need check the value of selections here with my project.

yzhang88
Contributor III
Contributor III
Author

figured out the solution, it returns the correct result.

=if( wildmatch ( GetFieldSelections (Code, ','), '*A*','*B*', '*C*','*D*'), 1, 0)