How can i optimize the if condition as post 15 or more condition sometime it works and somitime not

Ok.
Perhaps insert some breakpoints before the If-sentence and use the “Locals” panel to check the value of your String variable and Array, and also perform some “live testing” in the “Immediate” Panel.

Alternatively try with a List(Of String) for the countries to see if that makes a difference.

Locals Panel
locals

Immediate Panel
immediate

Regards
Soren

1 Like