Basically what I'm trying to do is replace a symbol like ™, ® etc with something else but when I call
myString = myString.Replace("®", "something else")
Its doesn't do anything
Any Ideas?
try myString.Replace("\u00A9", "else"); you have to escape the ©
When you use String.Replace
you create a new string. It is a very common mistake to believe the the supplied string is modified. However, strings in .NET are immutable and cannot be modified.
You have to call it like this:
myString = myString.Replace("®", "something else");
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With