I'm using the memoir class for a thesis, and want no page numbering of the front matter including the TOC. Have followed the answer to Table of contents with page style empty which does remove the page numbering of the first page of the TOC. My TOC is three pages long, and the last 2 pages still has a heading with roman page numbering. Minimal example below here:
\documentclass[danish,12pt,a4paper,oneside,openany]{memoir}
\AtBeginDocument{\addtocontents{toc}{\protect\thispagestyle{empty}}}
\begin{document}
\frontmatter
\pagestyle{empty}
\include{frontmatter/titlepage}
\include{frontmatter/abstract}
\tableofcontents*
\pagestyle{headings}
\mainmatter
...
\pagestyle{empty}
command before\frontmatter
.\clearpage
after the\tableofcontents*
command.