# Issue with changing Appendix format

I believe there are many questions on this topic already answered. However, I tried all of them, but none of them worked with me. Perhaps someone can help me find the issue.

Currently, my TOC looks like this:

But, instead of "A" in the appendix, I want it to say "Appendix", like this

I tried this solution using Appendix package: https://stackoverflow.com/questions/5690679/add-appendix-before-a-in-thesis-toc But it does not work, it hangs when I compile it. Below you can see my code and all the packages that I'm using. Maybe some of them are conflicting.

%% document class
\documentclass[a4paper]{book}
\usepackage[table]{xcolor}
\usepackage[spanish,es-tabla]{babel}
\usepackage{ragged2e}
\usepackage[numbers]{natbib}
\usepackage{hyperref}
\usepackage{amssymb}
\usepackage{caption}
\usepackage{subcaption}
\usepackage{longtable}
\usepackage{enumerate} % needed for some options in enumerate
\usepackage{makeidx} % needed for creating an index
\usepackage{blindtext}
\usepackage{amsmath}
\usepackage{bigstrut}
\usepackage{upgreek}
\usepackage{listings}
\usepackage{color}
\usepackage{graphicx}
\usepackage{array}
\usepackage{tikz}
\usepackage[nottoc]{tocbibind}
\usepackage{fancyhdr}
\usepackage{titlesec}
\usepackage{pdfpages}
\usepackage{pdflscape}
\usepackage{titletoc}
\usepackage{appendix}
\titleformat*{\section}{\LARGE\bfseries}
\titleformat*{\subsection}{\Large\bfseries}
\titleformat*{\subsubsection}{\large\bfseries}
\titleformat*{\paragraph}{\large\bfseries}
\titleformat*{\subparagraph}{\large\bfseries}

\hypersetup{%
citecolor=black,
urlcolor=black}
\addto\captionsspanish{% Replace "english" with the language you use
\renewcommand{\contentsname}%
{Contenido}%
}
\newcommand\myhline{\noalign{\global\arrayrulewidth=1pt}\arrayrulecolor{white}\hline}

\arrayrulecolor{gray!80}

%% page settings
\input{settings/page}

%% own commands
\newcommand{\imp}[1]{\underline{\textit{#1}}}
\newcommand{\q}[1]{#1''}
\input{settings/macros}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{document}
My document, table of content, Chapters, Sections, etc

\bibliographystyle{ieeetran}
\bibliography{literature/library}

\begin{appendix}
\chapter{Just an example appendix}
\label{app_ex1}
\section{Section of appendix A}
\end{appendix}
\end{document}

• One issue here... load hyperref far later than it currently is being loaded. – Werner Dec 12 '18 at 8:01
• Everytime I try to use \begin{appendices} \end{appendices} the compiler hangs. I still don't know what's the issue. – Blue_Electronx Dec 12 '18 at 13:57

\documentclass{book}
\usepackage[table]{xcolor}
\usepackage[spanish,es-tabla]{babel}
\usepackage[titletoc]{appendix}
\usepackage{ragged2e}
\usepackage[numbers]{natbib}
\usepackage{amssymb}
\usepackage{caption}
\usepackage{subcaption}
\usepackage{longtable}
\usepackage{enumerate} % needed for some options in enumerate
\usepackage{makeidx} % needed for creating an index
\usepackage{blindtext}
\usepackage{amsmath}
\usepackage{bigstrut}
\usepackage{upgreek}
\usepackage{listings}
\usepackage{color}
\usepackage{graphicx}
\usepackage{array}
\usepackage{tikz}
\usepackage[nottoc]{tocbibind}
\usepackage{fancyhdr}
\usepackage{titlesec}
\usepackage{pdfpages}
\usepackage{pdflscape}
\usepackage{titletoc}
%\titleformat*{\chapter}{\LARGE\bfseries}
\titleformat*{\section}{\LARGE\bfseries}
\titleformat*{\subsection}{\Large\bfseries}
\titleformat*{\subsubsection}{\large\bfseries}
\titleformat*{\paragraph}{\large\bfseries}
\titleformat*{\subparagraph}{\large\bfseries}

\addto\captionsspanish{% Replace "english" with the language you use
\renewcommand{\contentsname}%
{Contenido}%
}
\newcommand\myhline{\noalign{\global\arrayrulewidth=1pt}\arrayrulecolor{white}\hline}

\arrayrulecolor{gray!80}

%% page settings
%\input{settings/page}
\usepackage{bookmark}


urlcolor=pink}

%% own commands
\newcommand{\imp}[1]{\underline{\textit{#1}}}
\newcommand{\q}[1]{#1''}
%\input{settings/macros}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{document}
\tableofcontents
\newpage
My document, table of content, Chapters, Sections, etc
asdfds
\bibliographystyle{ieeetran}
\bibliography{literature/library}

\begin{appendices}
\chapter{Just an example appendix}
\label{app_ex1}
\section{Section of appendix A}
\end{appendices}
\end{document}


Use \usepackage[titletoc]{appendix} and then use appendices environment will do the result.

Hopes this helps

• Why did you remove hyper setup and hyperreff package. Is that what's causing issues? – Blue_Electronx Dec 12 '18 at 13:06
• Yes, hyperref is the culprit. – TVM Boy Dec 14 '18 at 8:07
• Found that bookmark works instead hyperref. Can you use bookmark – TVM Boy Dec 14 '18 at 12:05
• Yes, I added the bookmark and works well now. – Blue_Electronx Dec 15 '18 at 14:27