I'm having that problem when creating the title of my thesis. I know it is because the command created in the .cls file is different from the declarations I'm using in the .tex file, but I can't find the problem. Here's my .tex part:

\author{My Name}
\university{Uni Name}

\supervisor{Supervisor name}
% Use the following command to change the declaration text:
%\renewcommand{\submittedtext}{INSERT NEW TEXT HERE}
\degree{Master's degree}


% A page with the abstract and running title and author etc may be
% required to be handed in separately. If this is not so, comment
% the following 3 lines:
% \begin{abstractseparate}
%   \input{Abstract/abstract}
% \end{abstractseparate}

And the .cls part:

\pagenumbering{roman} % Sasa Tomic
\setcounter{page}{0}  % Sasa Tomic
%  \null\vfill
  { \Huge {\bfseries {\@title}} \par}
  {\large \vspace*{30mm} {{\@crest} \par} \vspace*{20mm}}
  {{\Large \@author} \par}
  {\large \vspace*{1ex}
  {{\@collegeordept} \par}
  {{\@university} \par}
  {{\submittedtext} \par}
  {\it {\@degree} \par}
%     \null\vfill

Where am I wrong? Thank you all.

Edit: the error is

\maketitle ... } \vspace *{20mm} {{\submittedtext 
                                              } \par } \vspace *{1ex} 
l.109 \maketitle
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.

How do I fix the error?

  • What exactly is the question? Please show a complete document that can be used to reproduce your problem. Also paste the exact error message if there is any.
    – siracusa
    Aug 21, 2019 at 16:11
  • Added the link to my documents Aug 21, 2019 at 16:23
  • Note that links to mwe is usually frowned upon here as the question is likely to not be usable in the future as the external files are no longer available
    – daleif
    Aug 21, 2019 at 16:29
  • @daleif Which has happened now. The link is broken.
    – Roland
    Nov 10, 2021 at 5:35

1 Answer 1


The .cls defines


yet the \maketitle uses


You need to fix the .cls to define

  • Perfect, the error is gone! But now, whenever I try to add the supervisor name in \supervisor, when compiles it doesn't print the supervisor name. Here's the new .cls:\newcommand{\submittedtext}{{\textit{Supervisor}}} \newcommand{\supervisor}[1]{\def\@supervisor{#1}} and the .tex: \supervisor{supervisor name}. How do I fix this? Aug 21, 2019 at 16:38
  • @thranduil90: That's because \@supervisor - the macro that stores your supervisor name - is never used within \maketitle. So, you can define it all you want but it won't appear anywhere unless you update \maketitle to use it.
    – Werner
    Aug 21, 2019 at 16:42
  • I have added the following code: {\Large {\@supervisor} \par} \vspace*{1ex} to the \makefile in the .cls, and in the .tex I added: ` \supervisor{name}` after the \university but I'm getting the error on \maketitle again. Where am I wrong? Aug 21, 2019 at 16:49
  • @thranduil90: What error?
    – Werner
    Aug 21, 2019 at 17:23
  • Same as before, the one in the original post Aug 21, 2019 at 19:20

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .