I’ve thought of using several if’s, but I don’t think that it’s a better way instead of using the flow decisions, the if’s is much similiar to the flow decisions.
You can approach this situation by iterating or retrieving from a structure containing your cases. Here, your Var3 seems enough to distinguish each case consequently we can use a dictionary.
If you want to iterate over multiple tests, you can use an array and loop over its items.
I used Dictionary(Of String, Object) as values for the dictionary but you can use better structure if you’re familiar with them.
Variable
result As Boolean = False
cases As Dictionary(Of String, Dictionary(Of String, Object))
thisCase As Dictionary(Of String, Object)
Sequence
Below the TryGetValue doesn’t seem to assign the value to thisCase so I added an extra Assign activity
Assign
cases = New Dictionary(Of String, Dictionary(Of String, Object)) From { _
{"AU1901", New Dictionary(Of String, Object) From {{"limit", 1914}, {"message", "message content 1"}}}, _
{"AU1602", New Dictionary(Of String, Object) From {{"limit", 1614}, {"message", "message content 2"}}}, _
{"AU1406", New Dictionary(Of String, Object) From {{"limit", 2058}, {"message", "message content 3"}}} _
}
IfVar1 And Var2 And Var4.ToUpper <> "REP" And cases.TryGetValue(Var3, thisCase)