In my template .tex file (encoded as UTF-8), if I open it in TeXnicCenter, it displays correctly, and last line of the document is

(line 136) \end{document}

as one would expect from a .tex file. Opening the .tex file using a regular text editor also yields the same correct document. However, if I actually use File -> New -> File from Template and select my template, the opened document displays the following last lines:

(line 136) \end{document

(line 137) NUL

(line 138) NUL

Not only are there two new lines (with Null characters) formed when I create a new file from template, but the curly brace to close the .tex document is missing! What is going on here? I currently have to manually add the curly brace and delete the null characters every time I want to use my template.

EDIT: I should mention that I am using TeXnicCenter 2.0 Beta 1. I know, I know, I should update, but I would like to know whether this is a fundamental bug with my version or whether it is something I'm doing wrong.

-

## closed as off-topic by Speravir, Werner, Jubobs, ChrisS, mafpFeb 14 at 0:19

• This question does not fall within the scope of TeX, LaTeX or related typesetting systems as defined in the help center.
If this question can be reworded to fit the rules in the help center, please edit the question.

Could you double-check the encoding of your file? I personally like Notepad++ for checking and converting the file encoding, which tool did you use for creating the template? –  matth Feb 13 at 21:39
This sound very much like your problem: sourceforge.net/p/texniccenter/bugs/286 But they say it was closed long time ago. –  matth Feb 13 at 22:05
Thank you. I believe that is the definitive answer I need: so it is a bug with TeXnicCenter itself. I do think it is interesting that the bug was reported in 1.0, while I am using a relatively recent version. Nevertheless, time to update! –  Christopher A. Wong Feb 13 at 22:22
This question appears to be off-topic because it is about a bug in a beta version of TeXnicCenter, which was fixed at least with the latest stable version. –  Speravir Feb 13 at 23:23
@Speravir, yes, I could not confirm that my question was actually caused by a bug until now. I accept that the question is off-topic now. –  Christopher A. Wong Feb 14 at 0:55