|
I mean to replace the entire "[01:02:03]" with nothing. Your method doesn't work either,
But I found a stupid way to succeed.
string str = "[01: 19.50] I [01: 19.58] love you !!! [01: 19.58] [No!] [He is almost a neurosis] [Say this to someone the first time I meet] <br> Sorry. Are you sick! ";
str = str.Replace ("[", "Temp"). Replace ("]", "Temp");
Response.Write (System.Text.RegularExpressions.Regex.Replace (str, "Temp. *? Temp", ""));
Getting my intended purpose, the result is output:
I love you!!!
Sorry. Are you sick? |
|