@v-xida-msft I know this is an old thread, but I found it while looking for a solution to the same problem.
The difference with mine is the data I'm looking for doesn't match a nice pattern that can be easily defined by say.. add(indexof ......), 10
For example the email has this data:
Enquiry from: Firstname Lastname
Email: user@gmail.com
Phone Number: 0299999876
First Night: Thursday, 17 January 2019
Number of Nights: 2
In each of these lines the number of characters to add to the indexof is different for each email.
How can I use a function to grab everything between the colon and the new line, trim it and place it in a variable?
I will also put this in a new thread.