OpenOffice-OODoc - Simple question on generating a filename or title for an OOo document

Posted on Fri Nov 17 05:15:28 2006 by pnb
Simple question on generating a filename or title for an OOo document
Hello, I was most delighted to come accross the OpenOffice::OODoc module and I am using it to produce billing statements for information queried from a Perl::DBI database, great stuff....
My problem is that when I store my OODoc document with a filename like "Taylor.odt" it has the right filename on the harddrive but when the document opens in OpenOffice it's title is "Untitled". I've read through the man pages about the OODoc::Meta module but haven't gotten anywhere yet so I thought I would try here. How does one set the documents title or name?
I am creating a document from a template (.ott) file (basicaly just a letterhead with the date) and then saving it using the billed parties name as the filename.
Here are is my code:
use OpenOffice::OODoc; my $document = ooDocument(file=>'/home/pnb/DRC-07/Billing/Receipts/letterhead.ott'); ... (mostly $document->appendParagraph statements) ... my $statement = "/home/pnb/temp/$BusinessOrLastName.odt"; $document->save($statement);

Any help would be most appreciated. Thanks, Paul
Direct Responses: 3568 | Write a response