Archive for the 'LiveCycle ES PDF generation' Category

Dec 23 2008

Accessing MS-Office (custom) properties from LiveCycle ES processes

You probably know the case, you want to convert a file to PDF and add a fax page so you can send it to a customer using your fax-server, or you just want to add a coverpage so you can archive the file in a effective way and have all the metadata nicely grouped on that coverpage.

There are simple ways to let LiveCycle ES take care of that process for you. Below a short explanation of some of the available services that are relevant in this context.

Within LiveCycle Workbench ES, one of the services in the common category that you can use is “Export XMP“. This service will extract all the available metadata from a PDF document. If you have converted a MS-Office document to a PDF document, you will be surprised what metadata is also converted. All these properties are now accessible using the service above. Here is a screenshot of some custom properties in a Word document.

Result of the Export XMP service is an XML structure that you can query. For instance, if you want to know what’s in some of the custom metadata fields, you can check this file. Here is a sample of the result of an Export XMP service.

<?xpacket begin=”” id=”W5M0MpCehiHzreSzNTczkc9d”?>
<x:xmpmeta xmlns:x=”adobe:ns:meta/” x:xmptk=”Adobe XMP Core 4.2-jc015 52.349034, 2008 Jun 20 00:30:39-PDT (debug)”>
<rdf:RDF xmlns:rdf=”
http://www.w3.org/1999/02/22-rdf-syntax-ns#”>
<rdf:Description rdf:about=”"
xmlns:xmp=”
http://ns.adobe.com/xap/1.0/“>
<xmp:CreateDate>2008-12-23T09:45:28+01:00</xmp:CreateDate>
<xmp:CreatorTool>Acrobat PDFMaker 9.0 for Word</xmp:CreatorTool>
<xmp:ModifyDate>2008-12-23T09:45:28+01:00</xmp:ModifyDate>
<xmp:MetadataDate>2008-12-23T09:45:28+01:00</xmp:MetadataDate>
</rdf:Description>
<rdf:Description rdf:about=”"
xmlns:pdf=”
http://ns.adobe.com/pdf/1.3/“>
<pdf:Producer>Acrobat Distiller 9.0.0 (Windows)</pdf:Producer>
<pdf:Keywords>”PDF, Metadata”</pdf:Keywords>
</rdf:Description>
<rdf:Description rdf:about=”"
xmlns:dc=”
http://purl.org/dc/elements/1.1/“>
<dc:format>application/pdf</dc:format>
<dc:creator>
<rdf:Seq>
<rdf:li>Marcel van Espen</rdf:li>
</rdf:Seq>
</dc:creator>
<dc:title>
<rdf:Alt>
<rdf:li xml:lang=”x-default”>This is a test document</rdf:li>
</rdf:Alt>
</dc:title>
<dc:description>
<rdf:Alt>
<rdf:li xml:lang=”x-default”>Onderwerp</rdf:li>
</rdf:Alt>
</dc:description>
<dc:subject>
<rdf:Bag>
<rdf:li>PDF, Metadata</rdf:li>
</rdf:Bag>
</dc:subject>
</rdf:Description>
<rdf:Description rdf:about=”"
xmlns:pdfx=”
http://ns.adobe.com/pdfx/1.3/“>
<pdfx:Company>Adobe Systems Incorporated</pdfx:Company>
<pdfx:Department>Development</pdfx:Department>
<pdfx:Language>English</pdfx:Language>
<pdfx:Office>Amsterdam</pdfx:Office>
</rdf:Description>
</rdf:RDF>
</x:xmpmeta>
<?xpacket end=”w”?>

Now, you will see some familiar tags in there. If you would like to access the custom property Office (With value Amsterdam) as highlighted in bold above, you will need to do the following:

  1. Store the result data from the Export XMP service in a variable of type XML (for this example this will be xmpdocxml)
  2. Create a variable of type string (In this case it will be office) to store the office location (of course you can also put it in a form template, but this is out of scope for this example)
  3. Use a set value service to set /process_data/@Office = /process_data/xmpdocxml/x:xmpmeta/rdf:RDF/rdf:Description/pdfx:Office

That’s it. You can of course repeat this for all the other elements, and do what you like with it. I have created a simple example and made it available on acrobat.com. In the sample (zip file) I included a LiveCycle LCA file that you can import, a sample Word document and an XML file that is just showing you the metadata.

If this is too much for you, there is an even simpler service to retrieve the metadata from a document. This service, Export Metadata, gives you a nice XML structure that you can browse using your XPATH editor. Note that this only retrieves the basic metadata!

No responses yet

Aug 04 2008

How to configure the LiveCycle PDF Generator ES print driver?

Disease:

So you have installed LiveCycle ES Update 1 that includes a new feature for PDF Generator, a print driver for windows. This allows you to select the Adobe LiveCycle ES printer from your printer list. The print job results in a PDF file that is centrally generated on a configured LiveCycle ES Server. Here is a screenshot of the “select printer” dialogue within MS-Word.

Printer Dialogue in MS-Word

Now it is clear how to initiate a PDF conversion process. But where does your file end-up?

Prescription:

There is a couple of things to take into account.

1. When installing the print driver via http://servername:port-number/pdfg-ipp/install you will be asked to provide a username. The account that is used here is an account that is known within LiveCycle ES (either synchronized with your directory, or a native account). The email-address that is known within LiveCycle ES is the one that is used to return the results to.

2. On the server-side you will need to configure a mail server that can be used for sending the results. Typically this is an smtp server that will be used. Now you will need to configure this using the LiveCycle ES Admin UI. Go to “Services” -> “Applications and Services” -> “Service Management”. Now look for a service called “provider.email_sendmail_service” and click on it. You will find the screen as shown below.

Configuring sendmail service

Just to make sure stop and start the service, and you should be fine.

Tips to stay healthy:

Just remember, when deploying this solution accross your organization, make sure that the users install the print driver with an account that points to their email address. Don’t use one address for everybody. Lastly, make sure that every account that is used, also has the proper user rights assigned to it. (Or even better, work with the groups and roles available within the User Management)

3 responses so far

Jun 25 2008

Anonymous Web UI for PDF Generator

Disease:

If you have upgraded to LiveCycle ES from a previous version of PDF Generator or even Adobe Elements Server, you may have noticed that the Web UI for generating PDF files is only accessible for those that have a login to the server, and for those that have the proper rights to use the PDF Generator services. In the past there was a URL where everybody could go to server-based PDF Generation.

Prescription:

Of course you could start to develop your own web-page to offer this service to anybody within your company, but actually there is a documented solution for this. In the LiveCycle ES LiveDocs on our website, there is a topic called Quick Start: Converting a Microsoft Word document to a PDF document using LiveCycle Remoting“. This specific sample uses LiveCycle Remoting to call the standard PDF Conversion process that is part of LC ES. Click here to access the page that contains the code needed.

Tips to stay healthy:

If you take the code described above, and open it using Adobe Flex, you can create a SWF file there that you can post on a web server. The result looks like this:

It will take you 30 minutes to do the whole process, and you will have a working process. Make sure you link to the swc files in the LiveCycle ES SDK (located in C:\Adobe\LiveCycle8\LiveCycle_ES_SDK\misc\DataServices\Client-Libraries) when compiling the application.

No responses yet