# How do I set group headings for an index in Lyx?

I want to set group headings, in form of a corresponding letter, for an index in lyx. I have one main lyx file, containing links (with include) to other lyx files, placed in a subfolder.

I tried following, but it doesn't work.

First I created a file called test.ist in the same directory as my main lyx file, containing folling:

``````quote '>'
``````

In my lyx main file I opend document settings, changed the processor under Indexes to "makeindex" and entered in option field "-g -s test.ist" (without quotes)

The lines corresponding to index in my log file look like this

``````(C:\...\miktex\tex\latex\base\makeidx.sty

Package: makeidx 2000/03/29 v1.0m Standard LaTeX package
)
\@indexfile=\write3

Writing index file test.idx
``````

Also the -g option doesn't show any effect.

Do you have a clue what to do and may give me a hint, please? Thank you.

-

For example, for the style file `test.ist` of directory `/home/user123`, change `-g -s test.ist` to `-g -s "/home/user123/test.ist"`. The quotation marks are necessary if your directory contains spaces etc.
The problem is that LyX runs commands in a temporary directory, e.g. `/tmp/lyx_tmpdir.XYZ/lyx_tmpbuf1`. Hence, "makeindex" does not find the index style file "test.ist" there.
Maybe write a TeX document "test.tex" containing just the necessary packages ("makeidx", "babel"), "\makeindex", and as body "a\index{a} \printindex{}". Put "test.tex" together with "test.ist" in the same folder. First run latex on it in that folder, then run `makeindex -s test.ist test.tex`. Any error? Actually, finish with another latex run... Or post the whole error message on your question... –  e-birk Feb 13 '13 at 22:57