string title() method does not work on Danish characters

Max M maxm at mxm.dk
Wed Feb 27 10:45:29 EST 2002


I am writing strings from a database, and am using the title() method to 
format the look of the strings.

like 'this is a name: MAX MØLLER'.title()
 >>> Max MØller

But the Danish characters does not get the right case.

I tried:

import locale
locale.setlocale(locale.LC_ALL, 'de')

but get:

"C:\python\Python21\Lib\locale.py", line 374, in setlocale return 
_setlocale(category, locale) Error: locale setting not supported

What else can I do? Please.

regards Max M




More information about the Python-list mailing list