4

I am using

\documentclass[a4paper,12pt]{report}

with

\pagestyle{empty}

and then the pages with

\tableofcontents

\listoffigures

\listoftables

are numbered (foot, in the middle). How to get rid of the numbers on these pages? On other "not automatically generated pages" it is ok without numbers.

4

\tableofcontents and it's fellow commands \listoftables and \listoffigures use a the plain pagestyle. It's 'easy' to temporarily switch back to use empty, but it has to be restored afterwards, if page numbers are requested (for chapters etc.)

\documentclass[a4paper,12pt]{report}


\makeatletter
\let\latexps@plain\ps@plain   % Store definition
\let\ps@plain\ps@empty        % Use empty pagestyle (ps)
\makeatother



\begin{document}

\tableofcontents

\listoffigures

\listoftables


\clearpage
\makeatletter
\let\ps@plain\latexps@plain   % restore pagestyle 'plain' 
\makeatother


\chapter{First}

\end{document}

Alternative solution with xpatch package:

has to be restored afterwards, if page numbers are requested (for chapters etc.)

\documentclass[a4paper,12pt]{report}

\usepackage{xpatch}


\xapptocmd{\tableofcontents}{\thispagestyle{empty}}{}{}
\xapptocmd{\listoffigures}{\thispagestyle{empty}}{}{}
\xapptocmd{\listoftables}{\thispagestyle{empty}}{}{}

\begin{document}

\tableofcontents

\listoffigures

\listoftables



\chapter{First}

\chapter{Second}


\end{document}

Note, that both methods will clear page headers too.

| improve this answer | |
  • Thank you, the first one works. After \tableofcontents etc. I would like to restore pagestyle 'headings'. It works using – user70214 Jan 27 '15 at 11:14
  • \makeatletter \let\ps@headings\latexps@headings % restore pagestyle 'plain' \makeatother – user70214 Jan 27 '15 at 11:14
  • But, the numbers disappear on every 'first chapter' page. On these pages I would also like to have the page number top left (as in 'headings'). – user70214 Jan 27 '15 at 11:16

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.