This content has been marked as final. Show 4 replies
Read Resource Dcoument just reads the document form the repositary into a document variable,it does not do any data merging.So if the PDF in your repository is blank, the read resource will read a blank document into the document variable
I've had a few responses to a previous posting that make suggestions as to how to obtain my PDF with its data. There seem to have been two different approaches to resolving the problem - but I can get neither of them to work.
- One approach was to use the Read Resource Content operation to obtain the PDF (which I've done) and to then merge the form data into it. It was suggested that the import data operation found in the FormDataIntegration service could be used to accomplish this - however, the input parameters to this are both of type document - I have, of course, a document variable that contains the "empty" PDF, but the only variable that I has is of type xfaForm, and this can't be used an an input to this service... so I really am not clear on how I should use this service to get my data injected into the PDF document.
- Another approach seems to require taht I change the Submit buttons "Submit As" setting to PDF - supposedly this will allow me to reference the PDF via an xpath expression... but as I mention, the Submit button doesn't seem to do anything when I change its output from XDP to PDF.
I've been struggling with this (should be trivial) for weeks now - so if you can clarify what I should do, it would be immensely appreciated!
Since you are configuring a submit button, it sounds to me like you are trying to display a PDF form in Workspace, allow a user to fill in some form field data, submit the form and then finally have your process email the completed PDF with the user entered data merged.
There are two ways you can go about this, depending on the style of submit button you have designed in your form: Either 1) submit the whole PDF and then email it, or 2) submit the XDP data and design your process such that it merges the submitted XDP data with a PDF form template read from the repository and emails it. Let's go with 1) as its probably the easiest:
The xfaForm variable type that you are using is actually not suitable for use a "PDF submit" from a form. You need to use a variable of type "Document Form" and point the Form URL to your PDF template in the Repository. Also, enable the "render once" option in the Workbench property editor for your Document Form variable.
When the whole PDF is submitted from Workspace (because you have used the "Submit As PDF" option) the Document Form variable in your process will contain the bytes of the whole PDF. You can use a Set Value step to xpath into the Document Form variable and extract the entire document object. Then you can email it etc.
Alternatively if you are only submitting XDP data you must use an xfaForm variable. You will need to use a Set Value to extract the submitted XDP data from the xfaForm variable and then use Form Data Integrator to merge that data with a PDF template that you read from the repository using ReadResourceContent.
>- Another approach seems to require taht I change the Submit buttons "Submit As" setting to PDF
Maybe you are trying to submit the form with the free Reader rather