0

got a problem when changing my appendix. The problem is that tex is producing two extra blank pages which I want to be removed.

Before the problem:

Main.tex

[...]

\begin{appendix}
    \include{anhang/Apple1}
    \include{anhang/Apple2}
    \include{anhang/Apple3}
    \include{anhang/Banana1}
    \include{anhang/Banana2}
\end{appendix}

[...]

Content of anhang/Apple1:

\includepdf[pages=1,scale=.8, offset= 0 -75,pagecommand={\chapter{blabla}\label{somelabel}}]{pdf/anything.pdf}

Content of anhang/Apple2:

\includepdf[pages=1,scale=.8, offset= 0 -75,pagecommand={\chapter{blabla2}\label{anotherlabel}}]{pdf/another.pdf}

and so on...

This worked fine. No extra pages were included. But when extending my work there was a few more appendix and I didn't want to get a new entry for every single page. So I decided to change the appendix to:

[...]

\begin{appendix}
    \include{anhang/Apple}
    \include{anhang/Banana}
\end{appendix}

[...]

Content of anhang/Apple:

\chapter{Apple}

\includegraphics[width=15cm]{pdf/apple1.pdf}
\includegraphics[width=15cm]{pdf/apple2.pdf}
\includegraphics[width=15cm]{pdf/apple3.pdf}

same for banana. So hopefully you get my point. Tried to merge contents and not to have an extra appendix for every single pdf file. It looks okay this way but my problem is: TeX adds two extra blank pages BEFORE appendix A. If more information is needed please ask.

Anyone have some advice please? Thanks.

mho
  • 33

1 Answers1

0

i was able to solve this. Thanks to User richard sharing his answer here.

I combined the pdf files and used this:

\includepdf[pages=1,scale=.8, offset= 0 -75,pagecommand={\chapter{apple}\label{apple}}]{pdf/full.pdf}
\includepdf[pages=2-,scale=.8, offset= 0 -75,pagecommand={}]{pdf/full.pdf}
mho
  • 33