How should I handle this situation?
I set the Encoding to UTF8 but I still get errors...
I create that string (that I set to the WebBrowser.DocumentText
) from a MemoryStream
object and I'm ending it like this:
Byte[] buffer = new Byte[ms.Length];
buffer = ms.ToArray();
return System.Text.Encoding.UTF8.GetString(buffer);
What am I missing?