I'm at a loss why the proper code like this one would produce "undefined control sequence" at every \hline:

\begin{tabular}{ |c|c|c| } 
 cell1 & cell2 & cell3 \\ 
 cell4 & cell5 & cell6 \\ 
 cell7 & cell8 & cell9 \\ 

Maybe it has something to do with my imports?


\usepackage[utf8]{inputenc} % allow utf-8 input
\usepackage[T1]{fontenc}    % use 8-bit T1 fonts
\usepackage{url}            % simple URL typesetting
\usepackage{booktabs}       % professional-quality tables
\usepackage{amsfonts}       % blackboard math symbols
\usepackage{nicefrac}       % compact symbols for 1/2, etc.
\usepackage{microtype}      % microtypography

\usepackage{booktabs} % for professional tables
\usepackage{float} %to fix figures

\usepackage{amsfonts,amsmath,amssymb,amsthm,mathtools} % various math stuff
\usepackage{wrapfig}  % Allow wrapping of text around figures
\usepackage{mdwlist}  % Make list items closer together: itemize*, enumerate*
\usepackage{sidecap}  % For putting caption beside figure
\usepackage{bm,amsbsy} % for bold symbols

% \usepackage{subcaption}  % apparently contains errors

\usepackage{hyperref}       % hyperlinks
  • Unrelated to the question, but regarding your comment on the subcaption package. This line causes an error massage because the subfigure package and the subcaption package can not be used together. However, as the subfigure package is considered obsolete, you might want to use either the subcaption or the subfig package instead.
    – leandriis
    Commented Jul 3, 2019 at 11:32
  • By the way, your example code can be drastically reduced to the following: \documentclass{article} \usepackage{arydshln} \usepackage{makecell} \begin{document} \begin{tabular}{ |c|c|c| } \hline cell1 & cell2 & cell3 \\ cell4 & cell5 & cell6 \\ cell7 & cell8 & cell9 \\ \hline \end{tabular} \end{document}
    – leandriis
    Commented Jul 3, 2019 at 11:35

1 Answer 1


Commenting out:


solves the issue.

  • 6
    If you want to continue using the arydshln package, load the array package just before loading arydshln.
    – leandriis
    Commented Jul 3, 2019 at 11:30

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .