For my appendix I'm trying to change 3 things to my section numbering:
- Change to Alphabetical numbering
- Subsections of the appendix are not supposed to appear in the table of contents
- Numbering has to reset for my appendix, since I am using sections in my main part aswell
The result is supposed to look like this:
Appendix
A.1 Code 1
A.2 Code 2
For the table of contents its supposed to look like this:
5. Results ............. 50
Appendix ............... 51
I'm currently using the following code:
\documentclass[ DIV15,
liststotoc,
]{scrartcl}
\begin{document}
{
\renewcommand{\thesection}{\thesection\Alph{section}}
\renewcommand{\thesubsection}{\thesection.\Alph{subsection}}
}
\setcounter{section}{0}
\section*{Appendix}
\setcounter{section}{1}
\addtocontents{toc}{\protect\setcounter{tocdepth}{-1}}
\subsection{Code 1}
\subsection{Code 2}
\addtocontents{toc}{\protect\setcounter{tocdepth}{1}}
\end{document}
TexStudio compiles with no errors, but the page numbering for my appendix is still numeric. How can I change the numbering to alphabetical? I've tried \def instead of \renewcommand but it did not help.
Thanks a lot in advance, Phyrii
\appendix
command before the start of the appendix? If not then can you please expand your code snippets into a compliable minimal working example. In particular, it would help to know what document class you are using.