No Preamble for UTF8Encoding

If you ever need to write something to a stream without preamble for eg. „” in UTF8 encoding, try to use:

UTF8Encoding encoding = new UTF8Encoding(false, true);

instead of default:

UTF8Encoding encoding = Encoding.UTF8;

Back to Top
%d bloggers like this: