4

I have read questions about this, and people say that it is just to include the natbib package and the plainnat style. For some reason my references will not sort alphabetically. Any help on this would be much appreciated! I am really new to LaTeX ...

My commands:

\documentclass[a4paper,norsk]{article}
\usepackage{amstext}
\usepackage{makeidx}
\usepackage{graphicx}
\usepackage[comma,authoryear]{natbib}
\usepackage[norsk]{babel}
\usepackage[hmargin=3cm,vmargin=3.5cm]{geometry}
\pagestyle{plain}

\begin{document}

\begin{thebibliography}{56}

\end{thebibliography}

\printindex

\bibliographystyle{plainnat}

\end{document}
0

1 Answer 1

2

The command to print the bibliography in natbib is \bibliography{<your-bib-file>}. You don't use \begin{thebibliography} ... \end{thebibliography}.

So the following document should work:

\documentclass[a4paper,norsk]{article}
\usepackage{amstext}
\usepackage{makeidx}
\usepackage{graphicx}
\usepackage[comma,authoryear]{natbib}
\usepackage[norsk]{babel}
\usepackage[hmargin=3cm,vmargin=3.5cm]{geometry}
\pagestyle{plain}

\begin{document}
Insert some \cite{} commands here to your citations.

\printindex

\bibliographystyle{plainnat}
\bibliography{<your-bib-file>} % Insert the name of your bib file here

\end{document}
2
  • I do not have a bib file, because I'm only going to use these for one article. Is it not possible to do it the simple way? Everything works as intended except for the alphabetibal references. Commented Feb 13, 2013 at 13:42
  • 1
    @Per There is no automatic way to sort citations in the manual {thebibliography} environment. You will save yourself time by creating a bib file with your references even if you don't use it again. See LaTeX and bibliography management tools.
    – Alan Munn
    Commented Feb 13, 2013 at 14:36

You must log in to answer this question.

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