This section provides a tutorial example on how to save text files with Nodepad by selecting the 'Unicode big endian' encoding option on the save file dialog box.
In the next test, I want to try the save function with the "Unicode big endian" encoding.
1. Run Notepad and open hello.utf-8 correctly with the UTF-8 encoding option selected.
2. Click the File > "Save As" menu. The "Save As" dialog box comes up.
3. Enter notepad_utf-16be as the new file name and select "Unicode big endian" option in the Encoding field.
4. Click the Save button. Notepad saves the text to a new file named as: notepad_utf-16be.txt.
5. To see how my text is saved by Notepad, I need to run my HEX dump program on notepad_utf-16be.txt:
Very nice. This is a perfect UTF-16 encoding file using the Big-Endian with BOM format.
Those leading 2 bytes represent the BOM flag, which is not part of the text.
Conclusion - The "Unicode big endian" encoding option of Notepad matches the "Big-Endian with BOM" format of
Unicode UTF-16 encoding.