[英]Underline function not working in MiKTeX?
This seems ridiculous but I'm using LaTeX for the first time in a while and when I attempt to underline like so:这看起来很荒谬,但我在一段时间内第一次使用 LaTeX,当我尝试像这样强调时:
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{graphicx}
...
\begin{document}
\maketitle
...
\subsection{}
\underline{ActorName} | Phone, Address, AgentName, Appears-In_Scene
\break
...
\end{document}
I get a math mode error:我收到数学模式错误:
! Missing $ inserted.
<inserted text>
$
l.15 ...me} Phone, Address, AgentName, Appears-In_
Scene
Any idea what is causing this and how to fix it?知道是什么原因造成的以及如何解决吗? I am not opening a math statement anywhere.
我不会在任何地方打开数学语句。 Also using BibTeX but I don't think that matters.
也使用 BibTeX,但我认为这不重要。
I am not opening a math statement anywhere.
我不会在任何地方打开数学语句。
Well, that's the problem.好吧,这就是问题所在。 You use a
_
which is a command which must only be used in math mode to write underscores.您使用
_
这是一个只能在数学模式下用于编写下划线的命令。 If you want to write a _, you can use \textunderscore
or escape the underscore with \_
如果你想写一个 _,你可以使用
\textunderscore
或者用\_
转义下划线
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{graphicx}
\title{text}
\author{names}
\begin{document}
\maketitle
...
\subsection{}
\underline{ActorName} | Phone, Address, AgentName, Appears-In\textunderscore Scene
\break
...
\end{document}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.