Skip to main content
JR Boulay
Community Expert
Community Expert
June 14, 2017
Answered

Spawning pages with OCGs

  • June 14, 2017
  • 1 reply
  • 800 views

Hi.

I have a PDF form (a contract) with 4 pages and 5 OCGs/layers (1 background and 4 layers for 4 differents contracts).

Page 3 need to be hidden when one of the four contract is selected (in a combobox).

Since Reader can only delete pages spawned from a template, I created a template from page 3, I hidden it and spawned a new page as page 3.

Layers are OK in the new spawned page.

This is something I use to do with not-layered PDFs, it's OK until now.

I used this script into the JS Console to spawn the page:

this.getTemplate("P3.allianz").spawn({nPage: 2, bRename: false, bOverlay: false});

I did this yesterday.

Issue is: from now, using this script from the combobox or from the Console spawn the page but the four layers are flattened on page 3.

When I clic the 5 layers icons to show/hide them: nothing change and all layers are displayed one over the other.

How did I do to spawn a page with its layers yesterday and why can not I do it anymore today?
What did I miss?

Is spawning layered pages supported?

Thank you.

(I cannot share this PDF form)

.

This topic has been closed for replies.
Correct answer JR Boulay

I understood the mistake that made me believe that I had succeeded the first time.

So the answer is no, we can not spawn layered pages: layers are systematically flattened…

1 reply

JR Boulay
Community Expert
JR BoulayCommunity ExpertAuthor
Community Expert
June 15, 2017

Is spawning layered pages supported?

This is my most important question because it is urgent and I find nothing in the documentation

Thank you.

Priere.gif

Acrobate du PDF, InDesigner et Photoshopographe
JR Boulay
Community Expert
JR BoulayCommunity ExpertAuthorCorrect answer
Community Expert
June 16, 2017

I understood the mistake that made me believe that I had succeeded the first time.

So the answer is no, we can not spawn layered pages: layers are systematically flattened…

Acrobate du PDF, InDesigner et Photoshopographe