# Missing number, treated as zero. What is wrong in here? [closed]

\documentclass[a4paper,12pt]{article}
\usepackage[dutch]{babel} % Quotes won't work without babel
\usepackage[utf8]{inputenc}  % This is very important!
\usepackage[T1]{fontenc}

\usepackage{graphicx}
\usepackage{tabularx}

\newcolumntype{Y}{>{\raggedright}X}

\begin{document}
\begin{tabularx}{\linewidth}{|Y|Y|}\hline
\multicolumn{}{}{Some Text.}
More Text and some Items below:
\begin{itemize}
\item Item1
\item Item2
\item Item3
\item Item4
\item Item5
\item Item6
\item Item7
\end{itemize}
& \begin{center} \resizebox{10cm}{!}{\includegraphics{pic.png}}\\ \textit{Picture Description} \end{center}
\tabularnewline \hline
\end{tabularx}
\end{document}


Error message is:

Missing number, treated as zero.
\relax
l.26 \end{tabularx}


-

## closed as too localized by Martin Schröder, Stephan Lehmke, egreg, Stefan Kottwitz♦Nov 20 '12 at 11:41

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

Considering that this is a simple syntax error with no connection to the question title, I'd advise to either formulate the question in a more general way or close this as too localized. – Stephan Lehmke Nov 20 '12 at 10:41
Ok - the question can be reopened after it's edited if desirable. – Stefan Kottwitz Nov 20 '12 at 11:41
The question led to a very useful answer in terms of error analysis. Cfr. \errorcontextlines 10000 – Serge Stroobandt Jan 14 '15 at 20:42

\multicolumn{}{}{Some Text.}


is certainly wrong. Please look into the manual to find out how to use it.

I don't know what you're trying to achieve, but if I use

\multicolumn{2}{c}{Some Text.}\\


## Error analysis

To make this at least marginally interesting to future users, here's a short explanation on how to find out about the error.

By setting

\errorcontextlines 10000


in the preamble, you get a lot more error context in the log.

With LaTeX, the default setting almost never gives a useable explanation...

Then, you will get the following in the log file:

! Missing number, treated as zero.
\relax
\@multispan #1->\@multicnt #1\relax
\loop \ifnum \@multicnt >\@ne \sp@n \rep...

\multicolumn #1#2#3->\multispan {#1}
<inserted text> ...e \multicolumn {}{}{Some Text.}
More Text and some Items ...


Note that the order is "from inner to outer", that is, the first (non-indented) line is the point where the error actually occurred. The line after that (indented) is the part of that line which isn't yet processed, so the point of error is exactly at the line break:

\@multispan #1->\@multicnt #1\relax
\loop \ifnum \@multicnt >\@ne \sp@n \rep...


The next "split line" gives, again at the split, the command from where this was called:

\multicolumn #1#2#3->\multispan {#1}

1. \multicolumn calls \multispan on its first argument.
2. \multispan in turn tries to assign its argument to a count register.
So still a bit of detective's work is needed, but in the end it's clear that the first argument of \multicolumn should not be empty, and you know where to look for the error.