
我對 LaTeX 非常陌生,我正在嘗試使用我已經創建的自己的引用樣式。現在我想知道如何使用這種風格。我找到了使用 natbib 套件的解決方案。但這不起作用。
我嘗試複製一個展示 natbib 如何運作的教程,但我無法複製它。程式碼如下:
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[english]{babel}
%Includes "References" in the table of contents
\usepackage[nottoc]{tocbibind}
%Import the natbib package and sets a bibliography style
\usepackage[square,numbers]{natbib}
\bibliographystyle{abbrvnat}
\begin{document}
\section{First Section}
This document is an example of \texttt{natbib} package using in bibliography management. Three items are cited: \textit{The \LaTeX\ Companion} book \cite{latexcompanion}, the Einstein journal paper \citet{einstein}, and the Donald Knuth's website \cite{knuthwebsite}. The \LaTeX\ related items are \cite{latexcompanion,knuthwebsite}.
\medskip
%Imports the bibliography file "sample.bib"
\bibliography{Lit}
\end{document}
當我使用 PDFLaTeX 編譯此文件時,引用未定義。當我使用 PDFLaTeX -> BibTeX -> PDFLaTeX -> PDFLaTeX 時,它會拋出以下錯誤:
ERROR - Cannot find 'Test.bcf'! INFO - ERRORS: 1
我需要做什麼?