Expand my Community achievements bar.

Using DDX to flatten a file

Avatar

Level 7

I have created the DXX below.However, when I use this module, it cuts a milti page form to a single page document. Can anyone explain why?

I also lose the logo from the file.

<?xml version="1.0" encoding="UTF-8"?>
<DDX xmlns="http://ns.adobe.com/DDX/1.0/">
  <PDF result="out.pdf">
    <PDF source="inDoc"/>
<NoForms/>
  </PDF>
</DDX>

Aditya

13 Replies

Avatar

Level 4

Did this ever get resolved?  I have the same problem except my ddx uses NoXFA

<?xml version="1.0" encoding="UTF-8"?>
<DDX xmlns="http://ns.adobe.com/DDX/1.0/">
    <PDF result="outdoc">
       <PDF source="doc1"/>
       <NoXFA/>
    </PDF>
</DDX>

My 8 pg interactive pdf after running it through this DDX outputs page 1 only.

Avatar

Level 7

How do I post a PDF? It only allows images.

This happens with any XFA dynamic doc with more than one page.

Aditya

Avatar

Former Community Member

What happens if you put pages="1-last" on your PDF source?

Avatar

Level 7

No luck...

Below is the ddx structure used

<DDX xmlns="http://ns.adobe.com/DDX/1.0/">
<PDF result="outDoc">
    <PDF source="inPDFDoc" pages="1-last"/>
<NoXFA/>
</PDF>
</DDX>

Aditya

Avatar

Level 2

Hi,

i was reading your posts and i am not sure if i have the anwsers, however let me point some things out since i believe it is a misunderstanding here.

<NoXFA/> ... Specifies that XFA-based forms in the parent element should be flattened.

This parameter is only working if the source is really a XFA document

<NoForms/> ... Specifies that all form fields in the parent document should be flattened.

This parameter is only working if the source is using form fields on a PDF document (created with the Acrobat Professional for example)

<PDF source="inPDFDoc">

This would expect a source named inPDFDoc which is not inPDFDoc.pdf

<PDF result="outDoc">

As a result it would be also a wise idea to set it to outDoc.pdf maybe this helps

You might miss also to try to apply to the input source to flatten meaning appliying NoXFA or NoForms there

example:

<DDX xmlns=”http://ns.adobe.com/DDX/1.0/”>
<PDF result=”rpt_flattenform_kpi_002.pdf”>
<PDF source=”doc1.source” pages="1-last">
<NoForms/>
</PDF>                     <---- see here cloeses the source
</PDF>
</DDX>

or

<DDX xmlns=”http://ns.adobe.com/DDX/1.0/”>
<PDF result=”rpt_xfastripping_001.pdf”>
<PDF source=”doc1.source” pages="1-last">

<NoXFA/>
</PDF>                     <---- see here cloeses the source
</PDF>
</DDX>

See if this is helping you to get the example working

rgs

Dieter

Avatar

Level 7

If you see the original post, I used NoForms and NoXFA later on. None of these seem to work. Have you tried using either of these parameters in your DDX for a multi page document? Did it work?

I have tried all your suggested combinations as per the previous posts, unless I missed anything?

Aditya

Avatar

Level 8

Aditya;

What version of LiveCycle are you using?

When your dynamic form gets chopped to one page is there any data in it, or is the data completely dumped?

Avatar

Level 7

I think it has to do with dynamic forms. It works well with static ones.

Does NoForms,NoXFA work with dynamic forms?

Aditya

Avatar

Level 8

Huum, interesting.  My suspicion is that the document is being merged with the data, but there is no request to re-render the form happening.  With Dynamic forms the document isn't fully rendered until it gets to the client (usually Reader).  Since the no-xfa is part of the merge, the request to render at client may be removed with the XFA.

Can you try merging the data with the form using LC Forms?  Then take the result and use assembler to do a no-xfa.

The other option would be to use LC Output to merge the template and data.  That would give you a non-interactive form without using no-xfa

Avatar

Level 7

Which module in Form? I need an interactive form hence, Output will not work.

Aditya

Avatar

Level 8

Forms is a module.  Try the renderPDFForm operation.

BTW - if you use noXFA you won't have an interactive PDF anymore.  That operation "flattens" the form.