Issue with \makelettertitle?

Asked by Eric Tramel

I've been working on a CV package which includes an introductory cover letter. Recently, I've been running into an issue with the cover letter support. Specifically, when I attempt to use the \makelettertitle command, the compilation gives me an error. Here is the code snippet...

\recipient{Title}{Address}
\date{\thedate}
\opening{Dear Sir or Madam,}
\closing{Best regards,}
\makelettertitle

... Letter Body ...

\makeletterclosing

And this is the error I get...

! Undefined control sequence.
\@date ->\thedate

l.5 \makelettertitle

If I comment out the \makelettertitle command, compilation runs without error and the document is produced correctly, just sans title material on the cover letter. Additionally, this error appears when trying to compile documents which have been untouched since the last working compile some weeks ago. All that has changed between now and then is perhaps a package update on my version of the moderncv package.

Any ideas on what could be causing this? Thanks.

-- Eric

Question information

Language:
English Edit question
Status:
Answered
For:
moderncv Edit question
Assignee:
Xavier Danaux Edit question
Last query:
Last reply:
Revision history for this message
Xavier Danaux (xdanaux) said :
#1

From the error message, it seems like you didn't define \thedate.

FYI, the compilation runs fine without \makelettertitle, because then \@date is not used. With \makelettertitle, \@date gets evaluated, and it points to \thedate as you requested with \date{\thedate}.

Can you help with this problem?

Provide an answer of your own, or ask Eric Tramel for more information if necessary.

To post a message you must log in.