20

Here is the sample code from test.tex: http://texblog.org/2012/05/14/list-of-symbols-or-abbreviations-nomenclature/

\documentclass{article} 
\usepackage{nomencl}
\makenomenclature
\renewcommand{\nomname}{Time Zones}
\begin{document}
UTC\nomenclature{UTC}{Coordinated Universal Time} is 3 hours behind ADT\nomenclature{ADT}{Atlantic Daylight Time} and 10 hours ahead of EST\nomenclature{EST}{Eastern Standard Time}.
\printnomenclature
\small\hfill Created by http://texblog.org
\end{document}

I ran this on TexStudio. pdfLatex --> MakeIndex --> pdfLatex

Errors when I ran MakeIndex:

Process started: makeindex.exe "test".idx

Input index file test.idx not found. Usage: makeindex.exe [-ilqrcgLT] [-s sty] [-o ind] [-t log] [-p num] [idx0 idx1 ...]

Process exited with error(s)

Errors when I ran pdfLatex

No file test.nls.

Thank you for your help!

2
  • 2
    Read Section 2 of the »nomencl« manual. Commented Feb 19, 2014 at 16:40
  • And the sample source also points out in detail what to do to get the nomenclature. Commented Feb 19, 2014 at 17:02

1 Answer 1

28

If every one reads manuals, then we will have very less questions here and less reputation too ;)

To make nomenclature you have to pdflatex the .tex file and then run this command:

makeindex -s nomencl.ist -t "<file name>.nlg" -o "<file name>.nls" "<file name>.nlo"

where <file name> is the name without .tex extension (myfile if I have myfile.tex).

Then again pdflatex myfile.tex.

Now the question is how to run makeindex with all those arguments in texstudio.

You can create a user command for this. Go to OptionsConfigure TeXstudio. In the window that appears, choose Build tab on the left side. Search for User Commands. (You may have to click Add button with a green +). Type

Make Nomenclature

just after user0: (0,or 1 0r 2, depending on how many use commands you already have) in the first box. In the second box type:

makeindex -s nomencl.ist -t %.nlg -o %.nls %.nlo

Now OK it. Illustration below.

enter image description here

Now you have a menu under ToolsUser with a short key also.

enter image description here

Now run pdflatexMake Nomeclaturepdflatex. Hope things are now clear.

As another option, you can install the cool automation tool arara and create a User Command for arara (as mentioned above) and make all three compilation clicks in one go. You have to add these lines:

% arara: pdflatex
% arara: nomencl
% arara: pdflatex

just before your \documentclass command (or anywhere in the document), and compile using

arara myfile

using your User Command.

9
  • 1
    With arara it's even easier.
    – egreg
    Commented Feb 20, 2014 at 0:30
  • @egreg Yes, I am writing it now :).
    – user11232
    Commented Feb 20, 2014 at 0:31
  • Thank you for your help Harish! Works perfectly! Have a great day :)
    – Kasun
    Commented Feb 22, 2014 at 23:06
  • This can be done through a one click in Texniccenter by modifying the pdflatex to avoid using arara or the two steps compilation. Does the new version of Texstudio provide this? Commented Feb 1, 2015 at 11:05
  • Thank you for the solution Mr. Harish Kumar. But I tried it, it did not work for me. I tried both options. Please help me. I posted a new post at this form My New Post here about my problem and mentioned that I couldn't solve my problem using solution in this post. Thank you in advance...
    – user75958
    Commented Apr 11, 2015 at 6:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .