Solved Nomenclature Not Generated in PDF Created by Visual Studio Code LaTeX Workshop Extension

Published on: 14 July 2023

The problem regarding not generation of nomenclature in pdf documents created by Visual Studio Code is finally solved.

You may have gone through search engines following the advice to display nomenclature but nothing worked like:

Popular searches regarding the same:

- Problem with the nomenclature
- nomencl latex won't show output

Solution

  • Step 1. In Visual Studio Code, Open File -> Preferences -> Settings and search for "latex-workshop.latex.tools" in that.
  • Step 2. Add the following code inside the "latex-workshop.latex.tools"
{
   "name": "makeindex",
   "command": "makeindex",
   "args": [
    "%DOCFILE%.nlo",
    "-s",
    "nomencl.ist",
    "-o",
    "%DOCFILE%.nls"
   ],
   "env": {}
},
  • Step 3. Again Open File -> Preferences -> Settings and search for "latex-workshop.latex.recipes" in that. Modify the following command:
{
   "name": "pdflatex -> bibtex -> pdflatex * 2",
   "tools": [
    "pdflatex",
    "bibtex",
    "pdflatex",
    "pdflatex"
   ]
},

like the below command:

{
   "name": "pdflatex -> bibtex -> makeindex -> pdflatex * 2",
   "tools": [
    "pdflatex",
    "bibtex",
    "makeindex",
    "pdflatex",
    "pdflatex"
   ]
},
  • Step 4. Save the file.
  • Step 5. Open the "LaTeX Workshop" Extension Menu in Visual Studio Code and run the command with "pdflatex -> bibtex -> makeindex -> pdflatex * 2" name.