How to check data exist in array data collection is integer?

Simple concept here

I need to use check if to check data in array then result True or False but I don’t know how .

Example

I have no idea how to write code in condition section for checking.

Thank you

@lovepong66

Try this expression in if activity

test_array.any(function(a) a.contains(1))

Try the below expression:

IsNumeric(yourVariable)

Hi @lovepong66

 intArray As Integer() = {1, 2, 3, 4, 5}
searchValue As Integer = 1

If intArray.Contains(searchValue) Then
    ' The value exists in the array
    LogMessage("Value found!")
Else
    ' The value does not exist in the array
    LogMessage("Value not found.")
End If

It’s not working (Contains function is not working with integer array data type)

@lovepong66

test_array.Contains(1)
1 Like

OMG!!! Thank you very much. It’s work!!!

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.