[Tex/LaTex] Remove dots for chapters in ToC with memoir

memoirtable of contents

I have seen similar posts but none seem to work. I simply need to remove the dots in the ToC between the chapter titles and the page numbers. I think the page numbers should line up (as if there were dots). This is using the memoir class. Here is my ToC info:

%%%% Do the ToC
\let\oldtoc\tableofcontents
\renewcommand{\tableofcontents}{\clearpage\pagestyle{toc}\oldtoc}

\renewcommand{\contentsname}{TABLE OF CONTENTS}
\renewcommand{\listfigurename}{LIST OF FIGURES}
\renewcommand{\listtablename}{LIST OF TABLES}
\renewcommand*{\tocheadstart}{\vspace*{-\topfiddle}}
\renewcommand*{\aftertoctitle}{\thispagestyle{plain}%
  \par\nobreak \mbox{}\hfill{\normalfont Page}\par\nobreak}
\renewcommand*{\cftchapterfont}{\normalfont}
\renewcommand*{\cftchapterpagefont}{\normalfont}
\renewcommand*{\cftchapterleader}{%
  \cftchapterfont\cftdotfill{\cftchapterdotsep}}
\renewcommand*{\cftchapterdotsep}{\cftdotsep}
%\renewcommand*{\cftchaptername}{CHAPTER~}
%%% no extra space before the entry
\setlength{\cftbeforechapterskip}{0pt plus 0pt}
%% no extra 'chapter' space in LoF/LoT
\renewcommand*{\insertchapterspace}{}

I tried everything that was suggested. Nothing seemed to make any difference. I am stuck with this format. Any suggestions would be greately appreciated!

Best Answer

You could just specify \renewcommand*{\cftchapterleader}{\hfill}:

enter image description here

\documentclass{memoir}% http://ctan.org/pkg/memoir

\renewcommand{\contentsname}{TABLE OF CONTENTS}
\renewcommand{\listfigurename}{LIST OF FIGURES}
\renewcommand{\listtablename}{LIST OF TABLES}
\renewcommand*{\cftchapterleader}{\hfill}

\begin{document}

\tableofcontents

\chapter{First chapter}
\section{First section}
\section{Second section}
\section{Last section}

\chapter{Second​​​ ​​​chapter}
\section{First section}
\section{Second section}
\section{Last section}

\chapter{Last chapter}
\section{First section}
\section{Second section}
\section{Last section}

​\end{document}

If you're interested in removing the section dots, include

\renewcommand*{\cftsectionleader}{\hfill}

as well. The dots are referred to as "leaders", hence the command \cft...leader.

I've removed all the other formatting-related stuff that doesn't pertain to the problem (like page style headings and \tableofcontents redefinition, for example).