# “Misplaced \noalign” error when compiling table made using \tabularx

Can someone help me fix the problem?

\begin{table*}[t]
\centering
\begin{tabularx}{\textwidth}{|l|l|l|}
\hline
\multicolumn{1}{|c|}{{\bf Field}} & \multicolumn{1}{c|}{{\bf Length (bits)}} & \multicolumn{1}{c|}{{\bf Description}}                                                                          \\ \hline
Message type                      & 6                                        & UID representing type of message               \\
\hline
Priority                          & 3                                        & 0-7: A value representing the urgency of message.  \\
\hline
Checksum flag                     & 1                                        & Value . %Set to 0 if no checksum exists \\
\hline
state              & 8                                        & UID \\
\hline
Source            & 5                                        & UID                                                                               \\
\hline
Source unit number                & 5                                        & UID                                                                                   \\ \hline
Source            & 5                                        & UID                                                                              \\ \hline
Destination       & 5                                        & UID                                                                           \\
\hline
Destination         & 5                                        & UID                                                                           \\ \hline
Destination     & 5                                        & UID                                                                          \\ \hline
Application & 16                                       & Representing length                                       \\
\hline
\end{tabularx}
\end{table*}

• Welcome to TeX.SX! You have %Set to 0 if no checksum exists \\ . I.e., the  \\  is commented out ... – Adam Liter Oct 5 '15 at 1:11

You should change the line

Checksum flag                     & 1                                        & Value is set to 1 if the data is followed by a 16-bit checksum. %Set to 0 if no checksum exists \\


onto

Checksum flag                     & 1                                        & Value is set to 1 if the data is followed by a 16-bit checksum.  \\ %Set to 0 if no checksum exists


In your version \\ is commented and LaTeX has more than 3 columns to align in your tabular.

• Haha...that was my stupid mistake then! Thanks. – Tina J Oct 5 '15 at 1:18