LaTeX forum ⇒ General\hline errors

LaTeX specific issues not fitting into one of the other forums of this category.
evlabiba
Posts: 8
Joined: Sat Nov 15, 2008 6:17 pm

\hline errors

Postby evlabiba » Thu Mar 12, 2009 6:30 pm

Hello
Why do I get a "Misplaced \noalign" error message when I use \hline outside the tabular environment?

  1. \begin{document}
  2. \hline
  3. Hello, \TeX{}-perts!
  4. \hline
  5. \end{document}


I'm a MikTeX 2.7 user.

Thx.

User avatar
localghost
Site Moderator
Posts: 9206
Joined: Fri Feb 02, 2007 12:06 pm
Location: Braunschweig, Germany

Postby localghost » Thu Mar 12, 2009 6:35 pm

evlabiba wrote:[...] Why do I get a "Misplaced \noalign" error message when I use \hline outside the tabular environment? [...]

It is simply not allowed to use this command outside a tabular environment. Replace \hline with \hrule and it will work.


Best regards
Thorsten¹
LaTeX Community Moderator
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes


¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1


Return to “General”

Who is online

Users browsing this forum: Google [Bot] and 6 guests