diff --git a/scripting/source/pyprov/mailmerge.py b/scripting/source/pyprov/mailmerge.py index 4654ad3..1e6c6e7 100755 --- a/scripting/source/pyprov/mailmerge.py +++ b/scripting/source/pyprov/mailmerge.py @@ -148,7 +148,7 @@ class PyMailSMTPService(unohelper.Base, XSmtpService): textbody = textbody.value except: pass - textbody = textbody.encode('utf-8') + textbody = unicode.encode(textbody, 'utf-8') if len(textbody): mimeEncoding = re.sub("charset=.*", "charset=UTF-8", flavor.MimeType)