Create UnicodeEncoding: using the big endian byte order and provide a Unicode byte order mark.
using System;
using System.Text;
class UnicodeEncodingExample {
public static void Main() {
UnicodeEncoding unicode = new UnicodeEncoding();
UnicodeEncoding unicodeLittleEndianBOM = new UnicodeEncoding(false, true);
UnicodeEncoding unicodeLittleEndianNoBOM =new UnicodeEncoding(false, false);
UnicodeEncoding unicodeBigEndianBOM =new UnicodeEncoding(true, true);
UnicodeEncoding unicodeBigEndianNoBOM =new UnicodeEncoding(true, false);
}
}
Related examples in the same category