文章目录
  1. 1. Latex “Error: Extra alignment tab has been changed to \cr. “
  2. 2. File ended while scanning use of \@writefile
  3. 3. 批量注释、取消注释
  4. 4. 表格注释

本文记录LaTeX编译,使用过程中的一些错误及其解决方案。

另外,还包括一些使用技巧,常见的元素使用方法等等。

便于自己以及后来人查阅解决。

我是留白。

我是留白。

Latex “Error: Extra alignment tab has been changed to \cr. “

是因为\begin{tabular}后面的参数指定为 A 列,而实际排列了 B 列数据。(A!=B)

解决方案:检查\begin{tabular}后面的r|c|l数量够不够实际列数。

File ended while scanning use of \@writefile

.aux不完整,可能是上次编译没通过。

解决方案:删除掉.aux文件,重新编译;如果依然不行,将.tex和其他图像文件、参考文献保留外,由系统编译生成的文件通通删掉,重新编译。

使用技巧

批量注释、取消注释

Ctrl+Shift+Alt+Right:批量注释

Ctrl+Shift+Alt+Left:取消注释

表格注释

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
\begin{table*}[htbp]
\caption{xx}
\begin{center}
\scalebox{0.6}{
\begin{tabular}{rccccccccccc}

%\toprule
\hline
\multirow{2}{*}{xx} & xx &... \\
... \tnote{*} \\
%\midrule
\hline
xxx
\hline
%\bottomrule
\end{tabular}
}
\begin{tablenotes}
\footnotesize
\item[*] * the note you wanna add
\end{tablenotes}
\label{xx}
\end{center}
\end{table*}
错误解决与优化 | Err&Opt