GeneralAppendix possible in latex?

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
ma501th
Posts: 50
Joined: Tue Apr 08, 2008 7:31 pm

Appendix possible in latex?

Post by ma501th »

Im attempting to add appendix into my report. I have tried different methods but not meeting my expectation.

I will need you guys help for the appendix please.

I'll the the appendix to appear on the contents page if possible but not as a chapter.

Thanks in advance

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

ma501th
Posts: 50
Joined: Tue Apr 08, 2008 7:31 pm

Appendix possible in latex?

Post by ma501th »

OK i have used the following commands:

Code: Select all

\appendix
\chapter{Questionnaire Requirement}
\chapter{Questionnaire Testing}
it seems to the job, but im worried because this is what appears when im compiling the .tex file

Code: Select all

! LaTeX Error: File `appendix.sty' not found.

Type X to quit or <RETURN> to proceed,
or enter new name. (Default extension: sty)

Enter file name: 
how can i fix this problem?
User avatar
Stefan Kottwitz
Site Admin
Posts: 10324
Joined: Mon Mar 10, 2008 9:44 pm

Appendix possible in latex?

Post by Stefan Kottwitz »

Hi,

it seems you typed \usepackage{appendix}, but that's not neccessary for an appendix. One small example:

Code: Select all

\documentclass[a4paper,10pt]{report}
\begin{document}
\tableofcontents
\chapter{One}
\appendix
%\addcontentsline{toc}{chapter}{Appendix}
\addtocontents{toc}{\protect\contentsline{chapter}{Appendix:}{}}
\chapter{Questionnaire Requirement}
\chapter{Questionnaire Testing}
\end{document}
Stefan
ma501th
Posts: 50
Joined: Tue Apr 08, 2008 7:31 pm

Re: Appendix possible in latex?

Post by ma501th »

cheers mate , works like a charm. your a star
Ali Sultan
Posts: 12
Joined: Sun Oct 02, 2016 5:09 am

Re: Appendix possible in latex?

Post by Ali Sultan »

and must we put chapters "Questionnaire Requirement and Questionnaire testing" in separate .tex files or what? Is this the best method to create an appendix in a report document class consisting from 6 chapters and 3 long appendices each is composed of multiple figures and tables?
User avatar
Stefan Kottwitz
Site Admin
Posts: 10324
Joined: Mon Mar 10, 2008 9:44 pm

Appendix possible in latex?

Post by Stefan Kottwitz »

Hi Ali,

welcome to the forum!

It is not necessary to put chapters in separate .tex files. The whole document can be a single .tex file.

It's just handy to use a file for each chapter and to use \include{filename} for including them in the main document. That's because you don't need to work with a huge file but split the work into small files for better handling. It's easy to comment out some \include (or to use \includeonly) so just the current chapter that you are working on is compiled.

Stefan
LaTeX.org admin
Ali Sultan
Posts: 12
Joined: Sun Oct 02, 2016 5:09 am

Re: Appendix possible in latex?

Post by Ali Sultan »

Thanks Stefan for your quick response. I agree that it is easier to put each chapter in a separate file and then call them in the main file which is exactly what I did. The problem is with appendices! I am still struggling with creating an appendix/appendices and call them in the main file as the case with chapters. Would you mind please provide a minimal code about how to create an appendix file and include it in the main file. Please include at least one figure and one table in the appendix file if possible. Should I save the created appendix file in the same folder with other chapters? Thanks again for your help
User avatar
Stefan Kottwitz
Site Admin
Posts: 10324
Joined: Mon Mar 10, 2008 9:44 pm

Appendix possible in latex?

Post by Stefan Kottwitz »

There is no difference to normal chapters. Make chapters as files in the appendix exactly the same as normal chapters. LaTeX just treats them as appendix chapters because of the \appendix command that starts an appendix. Then, the code makes normal chapters. LaTeX just uses letters for numbering and starts with A.

Stefan
LaTeX.org admin
Ali Sultan
Posts: 12
Joined: Sun Oct 02, 2016 5:09 am

Re: Appendix possible in latex?

Post by Ali Sultan »

Thanks again Stefan for your response. It worked:-) I just realized that I do have a typo error in the code which was causing the problem in reading figures of the appendices.
Post Reply