I'm working on my CV. When i compile the follwing code i get the following error : Undefined control sequence \makecvtitle The code doesn't work and i didn't find the problem source.

\documentclass[11pt,a4paper,sans]{moderncv} % Font sizes: 10, 11, or 12; paper sizes: a4paper, letterpaper, a5paper, legalpaper, executivepaper or landscape; font families: sans or roman

\moderncvstyle{casual} % CV theme - options include: 'casual' (default), 'classic', 'oldstyle' and 'banking'
\moderncvcolor{blue} % CV color - options include: 'blue' (default), 'orange', 'green', 'red', 'purple', 'grey' and 'black'

%\usepackage{lipsum} % Used for inserting dummy 'Lorem ipsum' text into the template

%\usepackage[scale=0.75]{geometry} % Reduce document margins
%\setlength{\hintscolumnwidth}{3cm} % Uncomment to change the width of the dates column
%\setlength{\makecvtitlenamewidth}{10cm} % For the 'classic' style, uncomment to adjust the width of the space allocated to your name


\clip (1em-.3em,-.3em) rectangle (5em +.5em ,.3em);
\clip (1em-.3em,-.3em) rectangle (#1em +.5em ,.3em);
\foreach \x in {1,2,...,5}{
 \path[fill=red] (\x em,0) circle (.25em);
\foreach \x in {1,2,...,5}{
 \draw (\x em,0) circle (.25em);

  % recompute lengths (in case we are switching from letter to resume, or vice versa)
  % optional detailed information box
      \ifthenelse{\isundefined{\@addressstreet}}{}{\makenewline\addresssymbol\@addressstreet %
        \ifthenelse{\equal{\@addresscity}{}}{}{\makenewline\@addresscity}} % if \addresstreet is defined, \addresscity will always be defined but could be empty
      \ifthenelse{\isundefined{\@mobile}}{}{\makenewline\mobilesymbol\@mobile} %
  % optional photo (pre-rendering)
     % \hspace*{\separatorcolumnwidth}%
  % name and title
  \ifthenelse{\lengthtest{\makecvtitlenamewidth=0pt}}% check for dummy value (equivalent to \ifdim\makecvtitlenamewidth=0pt)
 % \begin{minipage}[b]{\makecvtitlenamewidth}%
    \raggedright\namestyle{\@firstname\ \@familyname}\par\medskip%
  % detailed information
%  \llap{
%}% \llap is used to suppress the width of the box, allowing overlap if the value of makecvtitlenamewidth is forced
  % optional photo (rendering)
  % optional quote
  \par}% to avoid weird spacing bug at the first section if no blank line is left after \makecvtitle

% personal data
\title{Phd student}





Could you please help me ?

Thank you,

marked as duplicate by Mensch, Troy, Bobyandbob, user121799, Mico May 14 '18 at 15:31

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • you're missing an \end{document} – naphaneal Apr 18 '18 at 9:39
  • Yes you're right! just i forgot to write it in the question message. I will add it. But it's not the problem source. – Zoya Apr 18 '18 at 9:41
  • Maybe your template bases on an outdated moderncv version. It works for me with TeXLive2014. But with newer TL versions I get an error regarding undefined control sequence \makecvtitlenamewidth. – esdd Apr 18 '18 at 10:12
  • the error lies inside the renewcommand of makecvtitle. I'll try to figure it out later this day, if someone else does not beat me to it. – naphaneal Apr 18 '18 at 10:42
  • I downloed the moderncv from this link : ctan.org/tex-archive/macros/latex/contrib/moderncv?lang=en. I'm working with TeXstudio 2.7.0 – Zoya Apr 18 '18 at 15:15

Browse other questions tagged or ask your own question.