using System;
using System.Text.RegularExpressions;
public class Example
{
public static void Main()
{
string pattern = @"This.*";
string substitution = @"";
string input = @"\u0000Sp?\u0002\u0001A\u0000Sr?)\u0004£\u000Ex-opt-jms-destQ\u0001£\u0012x-opt-jms-msg-typeQ\u0005\u0000Ss?\u0000\u0000\u0000W\u0000\u0000\u0000\n¡0ID:06ecf56f-d295-4458-a981-d5badbb5b1a7:1:1:1-95@¡\u000Ftopic://MyTopic@@@@@@\u0083\u0000\u0000\u0001m^£\u0019\u0087\u0000Sw¡9&This is a test message sent out at 2019-09-23 17:00:10 PM";
RegexOptions options = RegexOptions.IgnoreCase | RegexOptions.Multiline;
Regex regex = new Regex(pattern, options);
string result = regex.Replace(input, substitution);
}
}
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for C#, please visit: https://msdn.microsoft.com/en-us/library/system.text.regularexpressions.regex(v=vs.110).aspx