我想将我的参考书目分为两部分:1)文章、书籍等。2)网页。
我正在使用多书目,但出了点问题。当我运行 Latex 时,它只显示第一个书目。
我尝试选择我的 latex 文档的单个部分,然后尝试单独运行它。对于这部分,它是有效的。
我的文件如下:
\documentclass[12pt,danish,a4paper]{article}
\usepackage[danish]{babel}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{graphicx}
\usepackage{multicol}
\usepackage{caption}
\usepackage{subcaption}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{float}
\usepackage{lastpage}
\usepackage{enumerate}
\usepackage{booktabs}
\setcounter{secnumdepth}{5}
\usepackage[font={small,it}]{caption}
\setcounter{tocdepth}{5}
\usepackage[hidelinks]{hyperref}
\usepackage{color}
\usepackage{enumitem}
\usepackage[top=3cm, bottom=3cm, left=2cm, right=2cm]{geometry}
\usepackage{setspace}
\usepackage[round]{natbib}
\usepackage{titlesec}
\usepackage[table,xcdraw]{xcolor}
\numberwithin{equation}{section}
\usepackage{fancyhdr}
\pagestyle{fancy}
\fancyhf{}
\chead{\emph{Title of text}}
\cfoot{\thepage\ of \pageref{mylastpage}}
\linespread{1.5}
\usepackage{setspace}
\usepackage{array,booktabs,tabularx}
\newcolumntype{L}{>{\arraybackslash}X}
\usepackage[nottoc,numbib]{tocbibind}
\usepackage[toc,page]{appendix}
\usepackage{multibib}
\newcites{web}{Webpages)
\begin{document}
text... \cite{xxx}, \citeweb{xxxx}.
\newpage
\bibliographystyle{agsm}
\bibliography{Litterature}
\bibliographystyleweb{agsm}
\bibliographyweb{Litterature}
\end{document}
序言有问题吗?似乎有什么东西困扰着我的第二份参考书目,尽管我没有发现任何错误?
答案1
根据multibib
-文档您必须bibtex
为 所创建的每个附加参考书目运行\newcites
。您正在使用 创建一个附加参考书目,名为“web” \newcites{web}{Webpages)
。因此您必须运行(假设您的文档名为yourdoc.tex
):
pdflatex yourdoc #or equivalently "yourdoc.tex"
bibtex yourdoc #or equivalently "yourdoc.aux"
bibtex web #or equivalently "web.aux"
pdflatex yourdoc
pdflatex yourdoc
如果你不想手动运行bibtex
,你可以使用latexmk
,能够处理multibib
。
答案2
\documentclass[12pt]{article}
\usepackage[backend=bibtex, defernumbers=true]{biblatex}
\addbibresource{\jobname-bib.bib}
\begin{document}
cite first article \cite{a1} plus second \cite{a2}
cite first book \cite{b1} then second \cite{b2}.
cite want to read \cite{w1}
\pagebreak{}
\printbibliography[type=book, heading=bibliography,title={Books}]
\printbibliography[type=article, heading=bibliography, title={Articles}]
\printbibliography[heading=subbibliography,keyword=want, title={Want to Read}]
% Create bibliography
\begin{filecontents}{\jobname-bib.bib}
@Book{b1,
author = {BOOK 1},
ALTeditor = {},
title = {TITLE},
publisher = {Publisher},
year = {year}
}
@Book{b2,
author = {BOOK 2},
ALTeditor = {},
title = {TITLE},
publisher = {Publisher},
year = {year}
}
@Article{a1,
author = {ART 1},
title = {TITLE},
journal = {Journal},
year = {year}
}
@Article{a2,
author = {ART 2},
title = {TITLE},
journal = {Journal},
year = {year}
}
@Reference{w1,
author = {WANT TO READ 1},
ALTeditor = {},
title = {TITLE},
publisher = {Publisher},
year = {year},
keywords = {want}
}
\end{filecontents}
\end{document}