0

I get this error when I compile on sharelatex, but the strange thing is that it appears only when I'm compiling in normal mode and instead it works fluently when I'm compiling in draft mode (with sharelatex built in).

The error suggestions tells me the error is in chapter1.aux (that I don't have).

l.7 \@LN
        {0}{18}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
misspelled it (e.g., `\hobx'), type `I' and the correct
spelling (e.g., `I\hbox'). Otherwise just continue,
and I'll forget about whatever was undefined.

Any suggestions are appreciated since I can't understand how to fix it.

UPDATE: chapter1.tex is a file that I still have to complete and as of now is super simple:

\chapter{Introduction}  %Title of the First Chapter

\ifpdf
    \graphicspath{{Chapter1/Figs/Raster/}{Chapter1/Figs/PDF/}{Chapter1/Figs/}}
\else
    \graphicspath{{Chapter1/Figs/Vector/}{Chapter1/Figs/}}
\fi

\todo[inline]{Write Introduction}

\section{Outline}
\todo[inline]{Write outline}
5
  • sharelatex isn't really involved, that just happens to be where you are running tex, but you have given no indication of your document how are we to help (short of searching the whole of ctan for a package that defines \@LN that you are presumably not loading. (most likely lineno.sty for line numbers – David Carlisle Jan 23 '18 at 19:42
  • I'm using the "(CUED) LaTeX PhD Thesis Template", and pdflatex as compiler. I'm not an expert of latex but since I guess chapter1.aux is created from chapter1.tex, I updated the question to include chapter1.tex – Daniele Jan 23 '18 at 19:51
  • In your preamble, add \makeatletter \providecommand{\@LN}[2]{} \makeatother. – Werner Jan 23 '18 at 20:27
  • Possibly related/cause: Problem with package lineno – Werner Jan 23 '18 at 21:18
  • @Werner ah well spotted, looks like a duplicate to me (+1 on your answer there:-) – David Carlisle Jan 23 '18 at 21:57

Browse other questions tagged or ask your own question.