Regex Expression query

Hi people,

Here is my sample string, I need a regex expression for matching a whole line next to “(you)”, with my sample string my output should be I am fine

Hello how are (you)
I am fine
Okk good

Thanks in advance!!!

http://regexstorm.net/tester?p=\(you\)\r\n(.*)\r\n&i=Hello+how+are+(you) I+am+fine Okk+good

1 Like

Try this out:

(?<=\(you\))(\r\n|\r|\n)(.*$)

might not work with the UiPath Matches activity, but this is a C# regex, which should work in an assign activity. Let me know if it works

1 Like

grafik

is using a variable length expression in the lookbehind group. (failing in regex101) but woking often in RegEx .Net implementations

2 Likes

(you).+\n(.+)

your result will save int Matches collection

1 Like

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