# [Tex/LaTex] Error “Missing number, treated as zero” – first compilation worked, second created the error

compilingerrorstexmaker

I hope some of you can help me with that problem. It is however difficult to give a minimal example. Here is the Problem:

I'm writing my master's thesis with TEXmaker and have splitted my document by using the \input command. The compilation always worked fine. But suddenly there is the error message

! Missing number, treated as zero. \advance
l.15 …egion (MP).\relax }}{29}{table.caption.28}
A number should have been here; I inserted 0'.

appears. The text location given in the message hasn't been changed and worked before. And the strange thing is, when I masked all inputs with % the compilation worked fine, I removeed the %again, the compilation still worked fine. I ran BIBTEX and PDFLATEX and it worked fine. I ran PDFLATEX for the last time (as it is recommended to get all refences right) the error appeared again with the identical message.

I again masked all inputs and ran PDFLATEX, the error remained. I repeated PDFLATEX, now it worked again though I haven't changed the code.

Please, does anyone know this weird error? It started when I used the "Fast Translate" (PDFLATEX + BIB(LA)TEX + 2x PDFLATEX + View PDF) in TEXmaker

(this was intended as a comment, but it's too long.)

the problem appeared with the fourth run. that means it happened because of some change that was made with the third run.

so what happened in the third run?

pdflatex was run after biblatex, and that made the information on the \cites available in the .aux file. so the problem is almost certainly associated with one of the \cites, but surely by something in the .aux file.

look in the line where the problem is reported and see if there's some sort of cross reference. is it in a "moving argument" like a section heading or a caption? if so, there are other questions here dealing with that.

the solution in such a case is usually to add \protect before the \cite or \ref` in the argument. but we can't be specific without an example to experiment with.