Dynamic Document Generator

Overview

This version is for Appian 23.2 and above. Cloud customers on a lower version of Appian that want to install this plugin should open a support case. Self-managed customers can find the latest jar for Appian 23.1 and lower version in the folder pre-23.2

Convert, merge and generate DOCX, PDF and XML files automatically in an Appian process

Key Features & Functionality

  • PDF from single DOCX with Fonts
    • Convert multiple DOCX files into a single PDF. Please note that the translation from DOCX to PDF is not always 1:1. The template may need to be tweaked or simplified to achieve the desired results.
  • PDF from DOCX without Fonts
    • Convert multiple DOCX files into a single PDF. Please note that the translation from DOCX to PDF is not always 1:1. The template may need to be tweaked or simplified to achieve the desired results. This will not support fonts.
  • PDF from XSL-FO Transformation
    • Uses XSLT to convert an XML to XSL-FO which is then converted to PDF
  • PDF from HTML
    • Converts an HTML document into a single page PDF.
  • PDF from HTML Transformation
    • Uses XSLT to convert an XML to HTML which is then converted to PDF
  • Text Doc from XSLT
    • Uses XSLT to convert an XML to a plain text document (such as HTML, another XML doc, etc).
  • DOCX from XHTML With Styling
    • Converts a valid XHTML file into a DOCX, allowing you to provide your own template file for style reference. Useful for creating dynamic documents that are editable
  • DOCX Merge
    • Merges one or more DOCX files together. If a header or footer exists in any document, they will be removed during the merge process.
    • A configurable separator can be specified: none, line break or page break

Function: xsltransform - Transform source XML using XSL Transform

Anonymous
  • Hi Raza, 

    We are using the Docx from XHTML service under the latest version of this plug in, and as mentioned below we are receiving the following error message in the logs:

    Exception in thread "ThreadPoolTaskExecutor-50668" java.lang.NoClassDefFoundError: com/lowagie/text/DocumentException

          at org.docx4j.org.xhtmlrenderer.docx.DocxRenderer.<init>(DocxRenderer.java:160)

          at org.docx4j.org.xhtmlrenderer.docx.DocxRenderer.<init>(DocxRenderer.java:85)

          at org.docx4j.convert.in.xhtml.XHTMLImporterImpl.getRenderer(XHTMLImporterImpl.java:271)

          at org.docx4j.convert.in.xhtml.XHTMLImporterImpl.convert(XHTMLImporterImpl.java:538)

          at com.appiancorp.ps.xmlfo.ss.DocxFromXhtml.runSmartService(DocxFromXhtml.java:49)

    Is there a patch for this issue?

  • Hi,

    We have requirement for converting hebrew language DOCX Document to PDF Document.
    We have tried to convert using "PDF from Single DOCX (with Fonts)" Smart Service.
    But Hebrew Language content is replaced with ### symbol in created PDF Document using this smart service.
    So we created constant, added two hebrew ttf document ("NotoSansHebrew-VariableFont_wdth,wght.ttf","NotoSerifHebrew-VariableFont_wdth,wght.ttf") and added as Font Documents in that Smart Service.
    But still we got the same PDF document with replaced ### symbol.

    Could you please suggest, what kind of font document we need to upload for hebrew language to get original Hebrew Language PDF Document?

  • Yes unfortunately, but it didn't seem to work

  • Hi Raza,

    We are using the PDF from HTML smart service and are needing to show/hide some sections conditionally. 
    However, it does not seem that the HTML style="display: none" is supported.

    Do you know of any other possible ways to show/hide that is supported?

    Thanks in advance.

  • Have you tried the convert Docx to PDF smart service and provided the fonts as inputs?

  • Hi Raza

    We are using the Appian version 21.3 and we have trouble converting DOCX and HTML to PDF when it contains Greek characters. They just appear like this ########. Is there a solution to that?

  • Hi Raza.mir,

    We are using plugin version 1.8.6, where we encountered issue with smart service "DOCX from XHTML", this smart service is failing with below error. When i checked node duration it is almost running for 4 and half days.

    "The amount of time allocated for the completion of an unattended activity was insufficient to allow the activity to complete."

    FYI - Appian version - 21.2

    The older version works as expected(1.8.2), could you please look into this.

    Thanks

  • do you have any plans to update this plugin. We are waiting for your response.

  • FYI - PDF from EML doesn't seem to work. Based on the error and googling it seems like some sort of jar conflict, but I'm not too sure.

    2021-09-17 13:13:31,286 [ThreadPoolTaskExecutor-4481] ERROR com.appiancorp.process.workpoller.WorkItemListener - The following exception occurred while attempting to complete work item [[WorkId: 45, EngineId: execution00, Request: UnattendedJavaActivityRequest:13213 as rob.turverey@groundswellcg.com by rob.turverey@groundswellcg.com, Response: null]] - Exception: 
    javax.resource.spi.work.WorkCompletedException: java.lang.NoSuchMethodError: com.sun.mail.util.LineInputStream.<init>(Ljava/io/InputStream;Z)V
    	at org.springframework.jca.work.SimpleTaskWorkManager$DelegatingWorkAdapter.run(SimpleTaskWorkManager.java:247)
    	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    	at java.lang.Thread.run(Thread.java:748)
    Caused by: java.lang.NoSuchMethodError: com.sun.mail.util.LineInputStream.<init>(Ljava/io/InputStream;Z)V
    	at javax.mail.internet.InternetHeaders.load(InternetHeaders.java:422)
    	at javax.mail.internet.InternetHeaders.<init>(InternetHeaders.java:380)
    	at javax.mail.internet.MimeMessage.createInternetHeaders(MimeMessage.java:2304)
    	at javax.mail.internet.MimeMessage.parse(MimeMessage.java:353)
    	at javax.mail.internet.MimeMessage.<init>(MimeMessage.java:223)
    	at org.nickrussler.mimeparser.MimeMessageConverter.convertToPdf(MimeMessageConverter.java:93)
    	at com.appiancorp.ps.xmlfo.ss.PdfFromEml.runSmartService(PdfFromEml.java:39)
    	at com.appiancorp.ps.xmlfo.ss.AbstractDocumentGeneration.run(AbstractDocumentGeneration.java:49)
    	at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.lambda$call$0(DefaultActivityExecutor.java:131)
    	at com.appiancorp.plugins.PluginUsageLogger.runWithPluginInformation(PluginUsageLogger.java:52)
    	at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.call(DefaultActivityExecutor.java:131)
    	at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.call(DefaultActivityExecutor.java:125)
    	at com.appiancorp.common.ContextClassLoaderSwitcher.runInContext(ContextClassLoaderSwitcher.java:27)
    	at com.appiancorp.process.runtime.framework.DefaultActivityExecutor.execute(DefaultActivityExecutor.java:125)
    	at com.appiancorp.process.engine.UnattendedJavaActivityRequest.execute(UnattendedJavaActivityRequest.java:88)
    	at com.appiancorp.process.engine.UnattendedJavaActivityRequestResponseCreator.getJavaActivityResultResponse(UnattendedJavaActivityRequestResponseCreator.java:21)
    	at com.appiancorp.process.engine.UnattendedJavaActivityRequest.getJavaActivityResultResponse(UnattendedJavaActivityRequest.java:67)
    	at com.appiancorp.process.engine.UnattendedJavaActivityRequest.execute0(UnattendedJavaActivityRequest.java:55)
    	at com.appiancorp.common.persistence.data.AppianDataUserContextProvider.executeWithConsistentDataReads(AppianDataUserContextProvider.java:116)
    	at com.appiancorp.process.engine.ProcessContinuationRequest.executeOuter(ProcessContinuationRequest.java:68)
    	at com.appiancorp.process.engine.ContinuationRequest.execute(ContinuationRequest.java:123)
    	at com.appiancorp.process.workpoller.UnattendedRequestHandlerBean.onMessage(UnattendedRequestHandlerBean.java:36)
    	at com.appiancorp.process.workpoller.WorkItem.run(WorkItem.java:94)
    	at org.springframework.jca.work.SimpleTaskWorkManager$DelegatingWorkAdapter.run(SimpleTaskWorkManager.java:239)