Possible Duplicate:

I've scanned various articles from different books and put together so there is a one pdf file now. I would like to make a table of content so that when I click on any article title, document viewer brings me appropriate page. Is it possible?

Note: By the way, I didn't use any ocr program so, you can't select words...

-

## marked as duplicate by Martin Schröder, Werner, doncherry, Paul Gaborit, Tom BombadilSep 29 '12 at 1:05

Is your one PDF file with the various articles produced with LaTeX? – doncherry Sep 28 '12 at 19:43
Welcome to TeX.sx! This question is very similar to tex.stackexchange.com/questions/11082/… . Please take a look at it as the information there might help you. If so, that's great, and we'll probably close this question as a duplicate just to keep the place tidy and to help people find answers quickly. If not, please edit your question here to explain why so that people can better focus their attention to help you. – doncherry Sep 28 '12 at 19:45
@doncherry Here the OP got multible PDFs, there one, which has to be enriched with a toc. Similar, but not the same. – Keks Dose Sep 28 '12 at 20:35
@KeksDose Similar enough to be a dupe imho. The two cases differ slightly in the argument structure of \includepdf, but the overall technique is the same. – doncherry Sep 28 '12 at 21:49

A slight modification of Keks' answer. You could use phantomsection to avoid introducing blank pages. You will have to specify the section title for table of contents separately using \addcontentsline{toc}{section}{<title here>}.

\documentclass{article}
\usepackage{pdfpages}
\usepackage{hyperref}

\begin{document}
\tableofcontents

\phantomsection
\includepdf[pages=-]{document1}

\phantomsection
\includepdf[pages=-]{document2}

\end{document}


However in the above example you can only link to first page of the pdf file. One way to link to pages within the pdf would be to add the pdf file in pieces,

\phantomsection
\includepdf[pages=1-5]{document3}

\phantomsection
\includepdf[pages=5-7]{document4}

\phantomsection
\includepdf[pages=8-]{document5}

-

In the folder with your scans make a *.tex-file, something like this:

    \documentclass{article}
\usepackage{pdfpages, hyperref}

\begin{document}
\tableofcontents
\section{document1}
\includepdf[pages=-]{document1}
\section{document2}
\includepdf{document2}
...
\end{document}


Read the manual of pdfpages for all its possibilities. It's a great package. Disclaimer: I did not test the file above.

-