Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I will first give you the codes then I will explain my problem:

\documentclass[a4paper,10]{article}
\usepackage[utf8]{inputenc}
\usepackage{natbib}
\usepackage{hyperref}

\begin{document}
  I hereby cite \citep{Adams_2013}.

  \bibliography{article_lib}
  \bibliographystyle{agsm}
\end{document}

Here is the BibTex file entry:

@MISC{Adams_2013,
author = {W. Adams},
title = {Breaching reservoirs},
month = {June},
year = {2013},
volume = {13},
number = {6},
language = {English},
howpublished = {AfroAIDSinfo Online},
organization = {AfroAIDSinfo},
note = {Retrieved 04 June 2013},
url = {http://www.afroaidsinfo.org/MRCWeb/appmanager/mrc/afroaidsinfo;jsessionid=qS16RJ2DzhkKvPp1h1xW14gmRSysHHTFbfzhn0QSZxv251QPJGxF!404223779?_nfpb=true&_windowLabel=editorials_1_1&editorials_1_1_actionOverride=%2Fpageflows%2Feditorials%2Fbegin&editorials_1_1cm_nodepath=%2FBEA+Repository%2FArticles%2FScience%2FClinical+Science%2FAntiretroviral+therapy%2FBreaching+HIV},
journal = {AfroAIDSinfo},
timestamp = {2013.06.04}
}

When I run the following in terminal:

latex example
bibtex example
latex example
latex example

I get the following error message:

The top-level auxiliary file: example.aux

I found no \bibstyle command---while reading file example.aux

(There was one error message)

How do I solve this problem? I need to include the url. Everything was working well until I included the url in the BibTeX database. I had the bibtex entry as @ARTICLE and it worked well, minus the url. Then, I changed it to @MISC with the url and now it doesn't work.

Following the advice on here I loaded the hyperref package to enable url usage. But, it doesn't work. I wrapped the url in the bibtex file in double quotation marks, but I got the same result.

Here is the thread whose advice I followed: How can I use BibTeX to cite a web page?

share|improve this question
    
Welcome to TeX.SX! –  Papiro Jun 25 '13 at 12:21
    
Your error indicates that you have not got the right information in the .aux file. Did you run LaTeX on exactly the file shown and BibTeX with exactly the same file name? –  Joseph Wright Jun 25 '13 at 12:52
    
Have you tried loading the har2nat and url packages (as well as natbib)? Then, delete the aux files and recompile (latex, bibtex, latex, latex). –  Mico Jun 25 '13 at 14:03

2 Answers 2

the problem is with the code %2F which occurs more than once in the url.

unfortunately, \harvardurl doesn't "protect" the url code as it should, so the % is taken as a comment and latex stops reading the line when it hits the first one, so you've got a runaway argument.

a possible patch is to add \usepackage{url} and \let\harvardurl\url. and specify [breaklinks] as an option to hyperref. the result is pretty awful, but really, it's terribly hard to get good results with a url that long!

share|improve this answer

I usually load hyperref (\usepackage[breaklinks,hidelinks]{hyperref}) add the \url{...} part straight into my bib editing program (BibDesk). That way you end up with:

@MISC{Adams_2013,
author = {W. Adams},
title = {Breaching reservoirs},
month = {June},
year = {2013},
volume = {13},
number = {6},
language = {English},
howpublished = {AfroAIDSinfo Online},
organization = {AfroAIDSinfo},
note = {Retrieved 04 June 2013},
url = {\url{http://www.afroaidsinfo.org/MRCWeb/appmanager/mrc/afroaidsinfo;jsessionid=qS16RJ2DzhkKvPp1h1xW14gmRSysHHTFbfzhn0QSZxv251QPJGxF!404223779?_nfpb=true&_windowLabel=editorials_1_1&editorials_1_1_actionOverride=%2Fpageflows%2Feditorials%2Fbegin&editorials_1_1cm_nodepath=%2FBEA+Repository%2FArticles%2FScience%2FClinical+Science%2FAntiretroviral+therapy%2FBreaching+HIV}},
journal = {AfroAIDSinfo},
timestamp = {2013.06.04}
}

Is that an option for you?

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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