I have this HTTP Request workflow that I send a value into. After sending a value and getting a value from the response. I would store it into a variable. I am testing to see If my Try/Catch would catch the error if the input value is wrong.
Here’s the error message that I get from my assign activity:
Assign CurrencyCode: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
I know that this happens If I had an extra character in the code, I was trying to catch it in the Catches part of the try catch by using and If else with condition:
exception.Message.Contains("Index was out of range")
If the condition is thru, I would throw another error message to my main file(I am using the REFramework). Unfortunately, It didn’t catch it. Is there anything wrong that I am doing here? Thank you.