# Printing selected chapters without affecting cross-referencing

I am writing my thesis in Lyx and for some reason, probably due to the style sheet, I am unable to print the complete thesis. It gives weird errors. However, individually all chapters are easily converted to PDF.

Is there a command that allows printing only a few selected chapters but does not affect referencing? I could then restart page numbering and get a quick fix to the problem.

-

Use \includeonly

\documentclass{book}

%\includeonly{Introduction}% uncomment this line if you want to include chapter "Introduction" only without affecting the referencing.

\begin{document}
\include{Introduction}
\include{Summary}
\end{document}

-
I was inspired by a comment in this tex.stackexchange.com/q/22109/2099. :-) – xport Jul 11 '11 at 6:34