title: How to programmatically open and modify ODT file from Calc Macro
body: <p>I am writing a Macro programm in a LibreOffice Calc spreadsheet. This macro should do the following (amongst other things):</p>
  <ul>
  <li>open an existing ODT text document as a template</li>
  <li>search and replace some strings with new values</li>
  <li>save a copy of this as a new file</li>
  <li>generate and open a PDF version</li>
  </ul>
  <p>Is this possible somehow using LibreOffice Basic only? I have found nothing in the Libreoffice docs and examples and only this slightly related answer here on SO: <a href="https://stackoverflow.com/questions/21039575/how-to-programatically-modify-open-libre-office-odt-document">How to programatically modify Open/Libre Office odt document?</a>
  Thanks!</p>