Writer: Populating Templates with external data

Hi,

We have multiple templates in Writer that we use to churn our documents (e.g. Appointment letters / Increment Letters). We currently open the template, save it as another file, populate the changable data (name / address) to make the appointment letter.

We have developed a web based for our office workflow. After approval, we want to feed the data to a Libreoffice Writer template and save it as a MS Word file.

Any help on how to do this will be highly appreciated.

Thanks,

Aseem

Aseem,

I’d suggest having a look at sections. Sections may be linked between documents.

The principle is:

  • A Writer source document holds a (named) section (or several if you want to store multiple common data) which contains the data you want to share with other Writer documents.
  • A target document holds a section at the appropriate place, which is set to link to the source document section (Format > Sections, select the Link option then point to the source document/section).

As a result, the target document section gets the very same text as the source one. Thus you may have one document with several sections holding the constant texts, with many “child” documents linked to its section-s.

Not sure if this what you’re looking for, but it might be of interest.

After approval, we want to feed the data to a Libreoffice Writer template and save it as a MS Word file.
Any help on how to do this will be highly appreciated.

I would advise against this completely.

Reason - Basically:

Always create and save your files in LibreOffice and save them in ODF format (ODT, ODS, etc.).
Always keep these files as their source. If you need other formats for distribution to partners, you can open an ODF file and save and distribute another format with ″ Save as… ″.

This way, you always have working files available in your system environment.

See:
https://wiki.documentfoundation.org/Faq/General/118


PS: Please also note that the use of styles in LibreOffice is more stringent.

Dear Harald,

Thank you so much for taking out time to respond to me … Your advise is sound and we will follow it…

Can you help me with the other part of our problem: How do we integrate LibreOffice with an external application - so that we can feed templates on LibreOffice with data coming from external applications?

Thanks,

Aseem

Can you help me with the other part of our problem…

Unfortunately not, as I have not used such applications before.

Since we are here on a site where users help other users, I think maybe someone else can suggest a solution.

If it is to be a business solution, it would be advisable to seek appropriate contact to professional help:

Professional Support