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.
Can you please help me?
Thanks a lot! :)
\chapterheading 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 '19 at 12:08.texextension withincludejust use\include{./Chapter/Chaptername}– David Carlisle Mar 25 '19 at 12:09\chapterline 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\chapterline -- and that means it's quite possibly in another file. – barbara beeton Mar 25 '19 at 13:57\included subfiles can make it even harder to find the culprit because the line number may not refer to the main file, but rather to an included file. It would be great if you could try to isolate the source of the error. A good way to do that is the binary search method described in https://tex.meta.stackexchange.com/q/228/35864 and https://www.codelord.net/2012/04/10/using-binary-search-for-debugging/. If you can show us code that reproduces the error you are much more likely to get a good answer – moewe Mar 25 '19 at 16:08no line here to endoften occurs when people use\\extensively in the text to end lines or paragraphs. In normal text one should usually not have to use\\. Paragraphs are ended with a blank line or\par.\\should be used almost exclusively in tables andtabular/array-like structures and in math mode. See https://tex.stackexchange.com/q/4690/35864 – moewe Mar 25 '19 at 16:11