Clear out / Reset IEnumerable variable from Matches

Hi guys, I am using an Matches activity to get a value from a string of text. I want to reset the Matches iEnumerable variable or clear it out of all string values that it currently has so that I can reuse the same iEnumerable variable without needing to worry about it still housing values I no longer need for the next part of the bot.

How do I do this? Thanks.

@css
One technique is to set matches to nothing: matches = Nothing

1 Like

Can you explain more? Am I acutally using an assign of MyMatchesVariable = Nothing, or “” or the Regex part is equal to “”?

@css
As it is an IEnumerable methods like Clear is not available. But with an assignment like following you can reset it to Nothing / Null

grafik

1 Like

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