[Tex/LaTex] Customizing table of contents

hyperreftable of contents

Could someone please give me a hint on how the virtual chapter is inserted ine the table of contents in the example below? I've tried to use \addcontentsline before this virtual chapter, but this splits sections of chapter 1 in the table of contents.

Best Answer

Use \addtocontents instead of \addcontentsline. The former is generic, the latter is used only to add "normal" entries.

Related Question