The below example presents two tables with an tabularx
environment (taken from package ltablex
) and a caption. After each tabularx
-table, the table counter skips one, as if both the caption
and the tabularx
environment increase it, while the latter shouldn't.
\documentclass{report}
\usepackage{ltablex}
\begin{document}
\begin{table}
\caption{Caption 1.} % "Table 1"
\begin{tabularx}{\linewidth}{|c|}
empty table
\end{tabularx}
\end{table}
\begin{table}
\caption{Caption 2.} % "Table 3"
\begin{tabularx}{\linewidth}{|c|}
empty table
\end{tabularx}
\end{table}
\end{document}
My reputation doesn't allow me to upload a picture, but the captions are Table 1 and Table 3 respectively.
Best Answer
ltablex
behaves like alongtable
, the reason why you should use the\caption
as a tabular line: