Select a phrase in the email header

Hi Everyone,

How can I get the data before the CH statement in the email header?

Thank you for your support and cooperation.

image

@ozgur.yukcan

If it is s string then use

TheHeadervalue.Split({"CH"},StringSplitOptions.None).First

Hi @ozgur.yukcan,

If it has structured form, you can split it for blanks.

emailSubject.Split(" ").FirstOrDefault()

Otherwise, You can extract the data before β€˜CH’ using the following expression:

emailSubject.Split({"CH"}, StringSplitOptions.None)(0).Trim

This will give you the desired result.

Best regards!"
Furkan

1 Like

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