I am preparing a book which will be printed in two separate volumes, and I'd like to show in the ToC the full content in both, either in two separate ToCs (Index for Volume I / Index for Volume II), or as a single ToC where the volume number becomes an unnumbered part which contains chapters and sections for that book.

I have looked around, but I can't find an answer. I am using memoir if it makes any difference.


This should work. Suppose the other volume is named volumetwo and the file volumetwo.toc already exists.


\tableofcontentsfrom{volumetwo}{Contents of Volume 2}

(It is a modification of original \tablofcontents and \@starttoc macros.)

Automated variant with one long TOC for both volumes (I just hadn't automated the choice of the top-level according to book/report/article class)

 \let\l@toplevel\l@part%    use for BOOK class
% \let\l@toplevel\l@chapter% use for REPORT class
% \let\l@toplevel\l@section% use for ARTICLE class


\begin{gentoc}{Complete Table of Contents}
\gentocfile{First volume}{volumeone}
\gentocfile{Second volume}{volumetwo}
  • Thanks a lot, I'll try it in a couple of hours and report back.
    – ludoo
    Jan 24 '12 at 11:12
  • Neat suggestion, though you may want to insert a \makeatother command following the \endgroup statement.
    – Mico
    Jan 24 '12 at 12:59
  • @Mico: Sorry, but I don't catch what you mean. The example I provided is fully operational.
    – yo'
    Jan 24 '12 at 13:02
  • 2
    @Mico -- in the example, \makeatletter is after \begingroup, so it will just disappear at the \endgroup. Jan 24 '12 at 13:53
  • 1
    In the end I went with a slightly different approach: each volume will have its own detailed toc, but before that I will place a general toc that includes volume I/II as parts, and each book's chapters skipping sections, using a hand-edited file. \makeatletter \def\pianoDellOpera#1{ \section*{#1\@mkboth{\MakeUppercase#1}{\MakeUppercase#1}}% \begingroup\makeatletter% \@input{piano_dell_opera.toc}% \endgroup% } It's exactly what I needed, thanks to everybody who contributed to this thread!
    – ludoo
    Jan 25 '12 at 10:30

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.