General ⇒ addcontentsline weird behavior
addcontentsline weird behavior
My problem is rather trivial: I need to add to contents following items
1) bibliography#1,
2) bibliography#2,
3) a list of figures
and
4) a list of tables.
These items locate at the end of my document so they should be in toc.
Came up to \addcontentsline which worked just fine, except:
1) It places specified titles at the beginning of toc,
2) It doesn't care about page numbering anyhow.
Of course, i can manually edit toc file, but it doesn't seem reasonable, for it is generated each time I compile tex file. I believe there is an automatic way to make latex to put my bibliographies and lists at the end of toc and take care about corresponding page numbering.
Please help me with this problem!
Thank You!
pm.
Learn LaTeX easily with newest books:
The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis
The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more
LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis
- Stefan Kottwitz
- Site Admin
- Posts: 10360
- Joined: Mon Mar 10, 2008 9:44 pm
addcontentsline weird behavior
welcome to the board!
Just put \addcontentsline at the corresponding position of your document. It could look like:
Code: Select all
\cleardoublepage
%\phantomsection % uncomment this if you are using hyperref
\addcontentsline{toc}{chapter}{Bibliography}
\bibliography{...}
Stefan
Re: addcontentsline weird behavior
Works just great.
I knew it should be easy, however was not obvious for me (doh!)
pm.