Graphics, Figures & TablesProblem with longtable package after update

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
Piotr
Posts: 7
Joined: Sun Aug 14, 2022 1:30 pm

Problem with longtable package after update

Post by Piotr »

Hello,
I have the following problem with the \longtable command. After recently updating all packages in MiKTeX to the latest version, I cannot compile the file. I get an error "Undefined control sequence" when creating a table with the \longtable command. I've tried everything. Please help.

In the main file I am compiling there is the following code:

Code: Select all

\documentclass[twoside,11pt,a4paper, openright]{mwrep}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{fontspec}					
\usepackage[titles]{tocloft}
\usepackage{polski} 
\usepackage[left=3 cm, right=2 cm, bottom=2.5cm, top=2.5cm]{geometry}
\usepackage{graphicx}
\usepackage{url}
\usepackage{array}
\usepackage{tabularx}
\usepackage{ltxtable}	
\usepackage{multirow}
\usepackage{pdfpages}
\usepackage{longtable}
\usepackage{tabularray}
\usepackage{tabu}
\usepackage{rotating}		
\usepackage{threeparttable} 
\usepackage{textgreek}      

\usepackage{upgreek}		
\usepackage{fancyvrb}								
\usepackage{fancyhdr}			
\usepackage{float}		
%\usepackage{tocbasic}

%\DeclareNewTOC[%
%		counterwithin=chapter,%
%		type=remarkbox,%
%		types=remarkboxes,%
%		float,%
%		floattype=4,%
%		name=Fot.,%
%		listname={Spis fotografii},%
%		indent=0%
%	]{lor}
%\setuptoc{lor}{chapteratlist}	
\makeatletter
	\renewcommand\@dotsep{.}
\makeatother

%\DeclareTOCStyleEntry[numwidth=2em]{tocline}{chapter}

%\newcommand*{\listofphotos}{\listoftoc{lor}}

\theoremstyle{definition}

\newcommand*{\defeq}{\stackrel{\text{def}}{=}}



\RecustomVerbatimCommand{\VerbatimInput}{VerbatimInput}
		{{fontsize=\tiny}, frame=lines, framesep=1em}

\usepackage{amsmath}

\usepackage[font=small, justification=centerlast, width=\textwidth, labelsep=period]{caption}

\SetSectionFormatting[breakbefore]{chapter}
	{24pt plus5pt minus2pt}
	{\FormatHangHeading{\LARGE}}
	{10pt plus0pt}
	
\SetSectionFormatting{section}
	{10pt plus0pt minus0pt}
	{\FormatHangHeading{\Large}}
	{10pt plus0pt}
	
\SetSectionFormatting{subsection}
	{10pt plus0pt minus0pt}
	{\FormatHangHeading{\large}}
	{10pt plus0pt}

\makeatletter
\renewcommand{\@biblabel}[1]{[#1]\hfill}
\makeatother

\renewcommand*{\figurename}{Pic.}
\renewcommand*{\tablename}{Tab.}


\setcounter{secnumdepth}{3}		
\renewcommand{\cftchapleader}{\bfseries\cftdotfill{\cftchapdotsep}}
\renewcommand{\cftchapdotsep}{\cftdotsep}
\renewcommand{\cftdotsep}{0.1}
\setlength{\cftfigindent}{0pt}
\setlength{\cfttabindent}{0pt}


\begin{document}
	\tableofcontents
	\include{Summary}
	\include{Symbols}
	\include{Introduction}
	\include{Chapter_I}
	\include{Chapter_II}
	\include{End}
	\include{Bibliography}
	\listoftables
	\listoffigures
%	\listofphotos

\end{document}
I have a separate file with a defined table:

Code: Select all

\begin{longtable}{|X|r@{,}l|r@{,}l|c|}
	\caption [Example]
		{Example of ...(citation:~\cite{book 1})} \\
 	\label{tab: example}		
	    		     		    		
	\tabularnewline
	\hline
	\multicolumn{1}{|c|}{\multirow{2}{*}{\centering{Argument}}} & \multicolumn{4}{c|}{Value} & \multicolumn{1}{c|}{\multirow{2}{*}{\centering{Symbol}}}
	\tabularnewline
	\cline{2-5}  & \multicolumn{2}{c|}{text 1} & \multicolumn{2}{c|}{text 2} & {}
	\tabularnewline
	\hline
	\centering {$T_1$} & \multicolumn{4}{c|}{450} & \centering{N $\cdot$ m}  	
	\tabularnewline
	\hline
	\centering {$T_{1\,\mathrm{max}}$} & \multicolumn{4}{c|}{720} & \centering{N $\cdot$ m} 
	\tabularnewline
	\hline
	\centering {$n_1$} & \multicolumn{4}{c|}{2100} & \centering{obr/min} 
	\tabularnewline
	\hline
	\centering {IT} & \multicolumn{4}{c|}{6} & {} 
	\tabularnewline
	\hline	
	\centering {Number, $N_{L1,\,2}$} & 4 & 5$\cdot 10^8$ & 1 & 6$\cdot 10^8$ & {}
	\tabularnewline
	\hline				
	\centering {$\m_n$} & \multicolumn{4}{c|}{3,333} & \centering{mm} 
	\tabularnewline
	\hline
	\centering {Height, $h^*_{aP}$} & \multicolumn{4}{c|}{1,4} & \centering{mm} 
	\tabularnewline
	\hline
	\centering {$\upalpha$} & \multicolumn{4}{c|}{20} & \centering{$^\circ$} 
	\tabularnewline
	\hline
	\centering {$\upbeta$} & \multicolumn{4}{c|}{28} & \centering{$^\circ$} 
	\tabularnewline
	\hline	
				
\end{longtable}
I attach the above file in the second chapter of my work (in the Chapter_II file):

Code: Select all

\chapter
	\section	
		text
	\section
		text
		\begin{small}
			\LTXtable{\textwidth}{file.tex}
		\end{small}

Maybe someone can help me to solve this problem...

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org
TikZ book
Post Reply