System.Text.RegularExpressions.Match cannot be serialized

Hi. I’m using Create Form Task and Wait for Form Task and Resume. I’m also using Regular Expressions and Matches activity. But whenever I run the workflow I get the following error that apparently I can’t use System.Text.RegularExpressions.Match type. Is that right?:

'System.Collections.Generic.IEnumerable1[System.Text.RegularExpressions.Match]’ cannot be serialized. Consider marking it with the DataContractAttribute attribute, and marking all of its members you want serialized with the DataMemberAttribute attribute. If the type is a collection, consider marking it with the CollectionDataContractAttribute. See the Microsoft .NET Framework documentation for other supported types.`

1 Like

System.Text.RegularExpression.Regex.Match(varStrg,“Pattern”)

Try this!
@atoi
Cheers

Could you please explain the reason?