how to write a unicode string to a file ?

S

Stef Mientki

hello,

By writing the following unicode string (I hope it can be send on this
mailing list)

Bücken

to a file

fh.write ( line )

I get the following error:

UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in
position 9: ordinal not in range(128)

How should I write such a string to a file ?

thanks,
Stef Mientki
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top