LibreOffice MailMerge and SSL

Since 2013, LibreOffice Writer has a known bug regarding the mail merge wizard: Sending merged mails using a SSL connection to the SMTP server will fail.

There’s a workaround (thanks to Andrea Tessadri) – one has to edit the python script responsible for sending the mails. It’s called mailmerge.py, and you’ll find it (on a linux box) under /usr/lib/libreoffice/program/ .

To make sending mails using SSL work, make sure that no LO process is running (check quickstart!). Now, open /usr/lib/libreoffice/program/mailmerge.py (on Linux: with root privileges), search for the line

self.server = smtplib.SMTP(server, port,timeout=tout)

and replace it by

self.server = smtplib.SMTP_SSL(server, port,timeout=tout)

Now, when sending merged documents via mail, don’t enable SSL in the mail settings; just set the port to 465. Now, sending merged documents as mail should work.

 

 

Transform ‚text‘ numbers into numerical values in openoffice.org calc

When pasting data into a Openoffice.org Calc Spreadsheet, it may happen that numerical values have been inserted as text values, so arithmetic operations on that values will fail or lead to unexpected results. To transform those numerical values into „plain“ numbers, i recently found a message board thread proposing a simple search/replace using regex: using the search pattern

^.*$

and the replacement pattern

&

should do the trick.