0

I am actually not sure if this is correct behaviour but I have an Appendix with multiple entries and it works fine. But in my Content table it shows all the entries. I think it should be hidden and not show all entries there. They should only display down in the appendix section. My appendix code is below. Is this expected behaviour?

\begin{document}

% --- Table of contents autogenerated ------------------------------------
\newpage
\tableofcontents
\thispagestyle{empty}

% --- Begin of Thesis ----------------------------------------------------
\mainmatter
\chapter{Introduction}
\label{chap:intro}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

\section{Contribution}
\label{sec:Unterkapitel1}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

\section{Relevance}
\label{sec:Unterkapitel2}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

\section{Methodology}
\label{sec:Unterkapitel3}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum \ref{appendix:A}. 

\chapter{First Chapter}
\label{chap:back}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

\section{First section of Chapter 1}
\label{sec:section1}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum \ref{appendix:B}.

\section{Section 2}
\label{sec:section2}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum \ref{appendix:C}.

\subsection{Subsection}
\label{sec:Subsection1}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum \ref{appendix:D}.


% --- Bibliography ------------------------------------------------------

%IEEE Citation [1]
\bibliographystyle{IEEEtran}
%for alphanumeric citation eg.: [ABC19]
%\bibliographystyle{alpha}

% List references I definitely want in the bibliography,
% regardless of whether or not I cite them in the thesis.

\newpage
\addcontentsline{toc}{chapter}{Bibliography}
\bibliography{testBib}

\newpage

% --- List of Figures ----------------------------------------------------

\addcontentsline{toc}{chapter}{List of Figures}
\listoffigures


% --- List of Tables -----------------------------------------------------

\newpage
\addcontentsline{toc}{chapter}{List of Tables}
\listoftables

% --- Appendix A -----------------------------------------------------

\backmatter
\appendix
\begin{appendices}
\chapter{Appendix}
\section{Appendix 1}
\label{appendix:A}
{\url{https:example.com}}

\section{Appendix 2}
\label{appendix:B}
{\url{https:example.com}}

\section{Appendix 3}
\label{appendix:C}
{\url{https:example.com}}

\section{Appendix 4}
\label{appendix:D}
{\url{https:example.com}}
\clearpage
\end{appendices}

\end{document}

And this is how it looks like in the content section.. I just want to see the Appendix but not all the appendices there. Just in the Appendix section itself..enter image description here

2
  • 1
    Hello, I think that a MWE would help get you a suitable answer. tex.meta.stackexchange.com/questions/228/…
    – anis
    Jan 12, 2023 at 15:01
  • Hello thank you, I edited my question and provided a code example. I hope this helps!
    – user288013
    Jan 12, 2023 at 23:30

1 Answer 1

0
+50

you did not provide a MWE because there is not the document class and the packages needed to compile the code. However I think that you are interested only about the appendix package that works at the same way with all the classes with chapters. First if you use the ambient \begin{appendices} do not use the \appendix command too because they call both the appendix but with different layout options, you can read about that in the package documentation. If you do not want to see in the TOC a section or a chapter you can just add *: \section*{name}. So if you want to show only the chapter named 'Appendix' you can leave \chapter{Appendix} but modify the sections with \section*{Appendix 1}.

2
  • That is actually what I wanted! Thank you! The Appendix in my content only shows Appendix and links to the section. And then there are all my appendices, perfect! Only one question remains and that is when I apply the * like you said the numbering in the text is not working - it shows to every appendix the same number. E.G.: This example can be found in the appendix ref{appendix:B} and ref{appendix:A} shows this: This example can be found in the appendix [1] and [1] Is it possible to have the correct numbering with \section*{Appendix 1} or not?
    – user288013
    Jan 13, 2023 at 21:52
  • 1
    Yes, there are many ways to do that I think the easiest is to use the command provided by the package hyperref: \hyperref[label]{text}. If you have an appendix as \section*{Appendix 1 } with \label{A1} you can use it to create an hyperlink with the text you want in it, in this case: \hyperref[A1]{appendix 1}.
    – kekko
    Jan 14, 2023 at 9:22

You must log in to answer this question.