strPattern = "\p{Lu}+[\s\S]+?(?=\n\r?\n|\z)"
"\p{Lu}+[\s\S]+?(?=\n\r?\n|\z)"
myMatches = System.Text.RegularExpressions.Regex.Matches(strtext, strPattern)
MatchCollection(3) { [ABC
Opp. Townhall
Corporate office
], [XYZ
Simson
Opp. Health Care
Office
], [PQR
Johny krishkot
Office
] }
Converted to an Array
myMatches.Cast(Of Match).Select(Function (x) x.Value).ToArray
[CheatSheet] - System.Text.RegularExpressions | RegEx - News / Tutorials - UiPath Community Forum