# How to change date format to German?

I use the \today comment, then it produces 26th February. However in my context, I want 26ten Februar. How can I change that?

• Actually »babel« with its language option ngerman should already do the trick. But you can also have a look at »isodate«. For more than these assumptions you should provide a self-contained and minimal example. – Thorsten Donig Feb 26 '14 at 16:56
• seems \usepackage[ngerman]{babel} does not work for me. – Ginger Feb 26 '14 at 16:58
• @Ginger You should post a minimal working example (MWE), so people can determine what is not working for you... – jub0bs Feb 26 '14 at 17:30
• The question was already answered, but as a native German speaker I have to say, that it is really unusual to write '26ten' or anything which resembles that. It should be written '26. Februar'. – user31729 Feb 26 '14 at 17:44
• It seems that you didn't even bother to provide a minimal example (→ -1) – Thorsten Donig Feb 27 '14 at 15:52

Try with the datetime package, by defining a new date format:

\newdateformat{myformat}{\THEDAY{ten }\monthname[\THEMONTH], \THEYEAR}


MWE:

\documentclass{article}

\usepackage[ngerman]{babel}
\usepackage{datetime}

\newdateformat{myformat}{\THEDAY{ten }\monthname[\THEMONTH], \THEYEAR}

\begin{document}

\myformat\today

\end{document}


Output:

## EDIT

If you can't load babel with the language ngerman, you can however load datetime as

\usepackage[ngerman]{datetime}


and define the date format as

\newdateformat{myformat}{\THEDAY{ten }\monthnamengerman[\THEMONTH], \THEYEAR}


MWE:

\documentclass{article}

\usepackage[english]{babel}
\usepackage[ngerman]{datetime}

\newdateformat{myformat}{\THEDAY{ten }\monthnamengerman[\THEMONTH], \THEYEAR}

\begin{document}

\myformat\today

\end{document}


Output:

• thanks@karlkoeller, but because i already have \usepackage[english]{babel}, then i cannot add \usepackage[ngerman]{babel}. If I do this\PassOptionsToPackage{english,ngerman}{babel}, Februry is still in English. – Ginger Feb 26 '14 at 20:37
• @Ginger Instead of \PassOptionToPackage, use \selectlanguage{ngerman} immediately after \begin{document} - – Sveinung Feb 26 '14 at 23:21
• @Ginger See the edited answer. – karlkoeller Feb 27 '14 at 6:15
• @Ginger: Although this seems to answer the question, this is formally completely wrong (as already mentioned in the comments to the questions). In German we don't write dates in this way. Mark my words! – Thorsten Donig Feb 27 '14 at 15:56