I want to insert a null character (ASCII Value 00) into an open file in Notepad. A program that is reading this file is expecting 00 at the end, but it's getting the ASCII value for space - 20.
How can I achieve this?
This is not possible to do with Notepad, however, it can be done with a more advanced editor.
With Notepad++
From HEX
From Base64
The mapping is:
NUL -> AA=
NUL NUL -> AAA=
NUL NUL NUL -> AAAA
AA==
in one place and AA=
in another.
Normal text editors such as Notepad usually do not have the capability to enter NUL characters into files. What you probably want to do is to use a "hex editor" (some text editors also have a "hex" mode). This will let you enter NUL characters, or any other byte you might need.
Alt+09
works for Tab, for example.