I have a main file (report.tex) which includes:


When I compile the subfile (Introduction.tex) on its own it had 1 line jumping to a 2nd page. I wanted to get my introduction to just cover 1 page so I included: \vspace{-0.75cm} at the beginning of the document to shift all the text up. Then I compiled the subfile again and it worked.

However, when compiling the main file (report.tex), the line again jumps to a 2nd page and the \vspace{-0.75cm} command gets ignored.

Is there a way to fix this?

  • Welcome to TeX.SE. It would be helpful if you composed a fully compilable minimal working example (MWE) including \documentclass and the appropriate packages that sets up the problem. While solving problems can be fun, setting them up is not. Then, those trying to help can simply cut and paste your MWE and get started on solving the problem. – samcarter_is_at_topanswers.xyz Apr 3 '19 at 13:37
  • Sometimes, shortening a text is easier than hacking TeX with \vspace{-0.75cm} or alike ;-) – jboockmann Apr 3 '19 at 13:41
  • I have not checked the code of subfile, but it is possible that it starts a new page. In that case, the negative \vspace needs to be in the subfile itself. Also, at the beginning of a page you need the starred form -- \vspace* -- otherwise it is ignored (basic TeX design). – barbara beeton Apr 3 '19 at 20:27
  • The command is in the subfile itself, and there it work if I only compile the subfile. But when compiling the main file it gets ignored. Also using \vspace* instead of \vspace does not work (it again does work for the subfile but it doesn't get transferred to the main file when compiling) – Freek Apr 4 '19 at 9:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.