using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Text.RegularExpressions; public class Test { public static void Main() { var texts = new List { "Paybacks: blah","Paybacks:blah","Paybacks blah"}; var pattern = new Regex(@"Paybacks[\s:]*(.*)", RegexOptions.IgnoreCase); texts.ForEach(text => Console.WriteLine(pattern.Match(text)?.Groups[1].Value)); } }