我见过一些.tex
使用 的文档\usepackage{attachfiles}
,但它们都是article
s。现在我正在处理一个moderncv
文档类并\usepackage{attachfiles}
返回一个错误。
这是我的代码:
\documentclass[11pt,spanish,a4paper,sans]{moderncv} % Font sizes: 10, 11, or 12; paper sizes: a4paper, letterpaper, a5paper, legalpaper, executivepaper or landscape; font families: sans or roman
\usepackage[utf8]{inputenc}
\usepackage{attachfile}
\moderncvstyle{casual} % CV theme - options include: 'casual' (default), 'classic', 'oldstyle' and 'banking'
\moderncvcolor{blue} % CV color - options include: 'blue' (default), 'orange', 'green', 'red', 'purple', 'grey' and 'black'
\usepackage{lipsum} % Used for inserting dummy 'Lorem ipsum' text into the template
\usepackage{multicol}
\usepackage[scale=0.75]{geometry} % Reduce document margins
%\setlength{\hintscolumnwidth}{3cm} % Uncomment to change the width of the dates column
%\setlength{\makecvtitlenamewidth}{10cm} % For the 'classic' style, uncomment to adjust the width of the space allocated to your name
%----------------------------------------------------------------------------------------
\begin{document}
错误如下:
! LaTeX Error: Option clash for package hyperref.
See the LaTeX manual or LaTeX Companion for explanation.
Type H <return> for immediate help.
...
l.37 \begin{document}
The package hyperref has already been loaded with options:
[,]
There has now been an attempt to load it with options
[unicode]
Adding the global options:
,,unicode
to your \documentclass declaration may fix this.
Try typing <return> to proceed...
答案1
使用 unicode 选项加载附加文件:
\usepackage[unicode]{attachfile}