1

I have been using TexLink with TexEditor. I am using DocumentClass elsarticle.

I have used the following snippet of code in my .bib file

@ONLINE {demand,
    key ="",
    year  = "",
   Howpublished= {\url},
   note={Retreived 2016-01-24}
   }

I ran the .tex file once, the .aux file associated with it once and the .tex file twice. But I am getting the references formatted as :

enter image description here

Instead I need them numbered as [3], [4]. The first two references are added correctly. I tried running the program several times but there was no change. The bibliography commands from my .tex document as below.

\begingroup
\raggedright
\bibliography{reference_PowerInterruption.bib}{21}
\bibliographystyle{apalike}
\setlength{\bibsep}{0pt}
\endgroup

Minimal working example added.

\documentclass[a4paper,11pt]{elsarticle}
\usepackage{times}%Use Times New Roman Font
\usepackage{url} %To recognize URLs
\begin{document}
\title{Integrated Model for Power Interruption Contracts}
\author{Lakshmi Palaparambil Dinesh}
\begingroup
\raggedright
\bibliography{reference_PowerInterruption.bib}{21}
\bibliographystyle{apalike}
\setlength{\bibsep}{0pt}
\endgroup
\end{document}
4
  • Welcome to TeX.SX! Please help us help you and add a minimal working example (MWE) that illustrates your problem. Reproducing the problem and finding out what the issue is will be much easier when we see compilable code, starting with \documentclass{...} and ending with \end{document}. Can you try adding number to the options of \documentclass{elsarticle} i.e. \documentclass[number]{elsarticle}. – Dai Bowen Oct 19 '16 at 20:33
  • @Dai , thanks a lot for your help. I tried adding number, but no change. I have added MWE in the question. – user5241675 Oct 19 '16 at 20:47
  • Or replacing \bibliographystyle{apalike} with \bibliographystyle{elsarticle-num}? – Dai Bowen Oct 19 '16 at 20:50
  • @Dai. Perfect. Great help. – user5241675 Oct 19 '16 at 20:57
1

The apalike bibliography style does not generate a numbered bibliography. Using the elsarticle-num bibliography style suggested in the documentation for the elsarticle class will instead generate a numeric bibliography style, likely in best keeping with the style desired by Elsevier.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.