# Strange “no line here to end” error

Unfortunately I didn't find any helpful question that already exists, so I need to open a new one on my problem.

I have two main documents I use. One is the main.tex with the entire thesis, and one is the SingleChapter.tex where I use single chapters for faster PDF creation. The files look pretty similar with both of them having some (working) header and settings part, and lots of included chapter.tex files.

When using the SingleChapter file everything works fine, but when using the main.tex I get the "no line here to end" error on

\chapter{Chaptername}
\include{./Chapter/Chaptername.tex}


Also, with commenting these two lines out the same error occurs in the same lines.

I don't get it.

• it will not generate the error that you state but almost always the \chapter heading should be inside the included file otherwise you get a forced page break after the heading. The error is telling you of a bad use of \\  but unless you show your code it is not possible to say what you have done wrong. – David Carlisle Mar 25 at 12:08
• also never use the explicit .tex extension with include just use \include{./Chapter/Chaptername} – David Carlisle Mar 25 at 12:09
• It's really better to put the \chapter line in the included file; leave it in the main file but comment it out -- that will allow you to take advantage of \includeonly. That said, the error is probably being reported for the line just previous to the \chapter line -- and that means it's quite possibly in another file. – barbara beeton Mar 25 at 13:57