I am new to Regex.
I read a PDF and output a string variable ‘text’.
I am trying to capture what comes after FROM: which are 3 lines followed by SUBJECT:. Example below.
ex. FROM: James Bond
Associate Director, C Team
Office of Towers
I’d like to capture the first line ‘FROM: James Bond’
Assigned James Bond as string variable ABC
I have Regex as
ABC= System.Text.RegularExpressions.Regex.Match( text, “(?<=FROM: ).*(?=SUBJECT:)”).value
The output is blank. Please help. Thank you!