How would I say 'if a subject contains' in terms of code?

Hi.

Welcome to the community.
Do you want to see if the subject contains the phrase “new enquiry” ?
The obvious answer is to use the CONTAINS method.
Would this post help you?
Check if string contains substring

Thank you.