Date: prev next · Thread: first prev next last
2011 Archives by date, by thread · List index


lee <lee@yun.yagibdah.de> writes:

I have a text document with mostly static data, and since it's kind of
a letter, there are a few things that are variable data, like a
company name, street, city, eventually a persons name and a
salutation.

Now I would like to make it so that I can press a button and be
presented with a form or the like that lets me fill in the variable
data, inserts the data at the appropriate places into the document,
saves the document to a file I specify and exports the document as PDF
with a password for access rights to the PDF file set.

How do I do that? Does it take some kind of advanced programming?

I'm making this a subthread in the hope that the progress in pursuing
different approaches is easier to follow when different approaches are
in different subthreads.

This subthread is about using the mailmerge tool to solve above problem.


What I found is that the mailmerge tool does produce results that can be
useful. Unfortunately, there seems to be a bug with remembering the data
sources:

Using the mailmerge wizard, I entered fields into my document as
needed. The data source for the fields was an LO spreadsheet. I was able
to produce PDF documents as I needed them.

The problem is that the documents can be produced only as long as the
data source, i. e. the spreadsheet, isn't modified. Once I put more
entries into the spreadsheet and save it, the fields appear from it as a
data source. The spreadsheet itself still shows up in the list of data
sources, though.

Since the modified spreadsheet still has the same name ("mm-testdata"),
LO adds a number to its name as a data source when adding it again, and
I now have two data sources: "mm-testdata" and "mm-testdata1". There
doesn't seem to be a way to remove a data source, and after two tries,
none of the two data sources contain any fields.

Since the name of the data source has changed --- or rather because the
fields in the data source the fields in the document are referring to
have disappeared -- the fields in the documents produced with the
mailmerge tool remain empty.

This means that each time I need to produce the PDF documents, I really
would have to gather all data in the spreadsheet in advance and to
recreate the "master" document from which to produce the PDF files with
mailmerge. After a while, I would end up with a multitude of broken
datasources, and it won't save me much work having to re-create the
"master" document every time.

So mailmerge is unfortunately broken, at least when using an LO
spreadsheet as a data source. I haven't tried to use something else
yet.


If I could use mailmerge, it would still leave me with the problem of
somehow saving additional data, i. e. the web pages, together with the
documents produced. I could probably find a solution for this, using the
reference numbers I already have.

Does someone know which datasources do work reliably for mailman?

-- 
Unsubscribe instructions: E-mail to users+help@global.libreoffice.org
In case of problems unsubscribing, write to postmaster@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.