I have a large document (with several directories and files, takes a long time to compile) with a table of contents. I would like to make a short latex document from it with the same table of contents but this time explicitely, so that I can manually edit the table of content (e.g. remove or rename headings, or select only parts of them).
I.e. I would like to edit the table of content without editing the 250 page document. The result should be a new .pdf file (the original project can stay the same, it doesn't need to be changed).
Here is an MNWE:
\documentclass[11pt,a4paper]{book}
\usepackage{a4wide}
%\usepackage{t1enc}
%\usepackage{pslatex}
\usepackage[ansinew]{inputenc}
\usepackage[german]{babel}
\usepackage{graphicx}
\usepackage{epstopdf}
\usepackage{amsbsy,amssymb,latexsym,layout}
\usepackage[centertags]{amsmath}
\usepackage{makeidx}
\usepackage{fancyhdr}
\usepackage[draft=true]{hyperref}
\makeindex
\newcommand{\vektor}[1]{\mathbf{\underline{#1}}}
\newcommand{\tensor}[1]{\mathbf{\underline{\underline{#1}}}}
\begin{document}
\select@language {german}
\contentsline {chapter}{Vorwort}{iii}{chapter*.1}
\end{document}
Usually I have:
\input{Skript.toc}
Instead of:
\select@language {german}
\contentsline {chapter}{Vorwort}{iii}{chapter*.1}
What I did was to just put the first two lines of the Skript.toc that produced the error...
Update: Here's an even shorter MNWE:
\documentclass[11pt,a4paper]{book}
\usepackage[german]{babel}
\makeindex
\begin{document}
\select@language {german}
\contentsline {chapter}{Vorwort}{iii}{chapter*.1}
\end{document}
The full Script.toc can be found here: http://pastebin.com/7MBtznL8
Thanks for any help...
\select@language {german}. You're already loading thebabelpackage with thegermanoption, so there would seem to be no need for the\select@languagecommand. At any rate, do observe that the\select@languagecommand contains a "special" character (@); hence, it should be used either inside a.styfile or has to be preceded by the\makeatlettercommand (and, ideally, should be followed by a\makeatothercommand). – Mico Aug 15 '12 at 13:24