Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
6

Structure of the Layers in the Linked PDF...

LEGEND ,
Aug 31, 2023 Aug 31, 2023

Has it been changed recently??? In the last few months...

 

Before - I was able to use:

myLObj.GraphicLayerOptions.GraphicLayers.Count

to iterate through layers in the linked PDF - myLObj - which meant that GraphicLayers were DIRECTLY childrens of the GraphicLayerOption...

 

Now, it needs to be:

myLObj.GraphicLayerOptions.GraphicLayers.Item(1).GraphicLayers.Count

Which means that there is an extra Layer - name of the file - in the Layers structure??

 

At least in VB...

 

TOPICS
Scripting
653
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 2 Correct answers

Community Expert , Sep 01, 2023 Sep 01, 2023

Hi @Robert at ID-Tasker ,

as you can see from both apps there could be differences in the structure of the layers.

A PDF exported from InDesign is showing all layers as sub-layers of the main layer that holds the name of the InDesign document where the PDF was exported from. Nothing new with that. Other PDFs would not have that structure. Depending how the layers came into place, e.g. were directly added in Acrobat or other apps.

 

Regards,
Uwe Laubender
( Adobe Community Expert )

Translate
Community Expert , Sep 01, 2023 Sep 01, 2023

Ah yes. "have" was missing. Corrected that.

And also yes, this specific structure with the name of the InDesiogn document is from InDesign exported PDFs.

It could be totally different with other PDFs that e.g. were edited with Acrobat Pro. It could be also different if someone edited a PDF exported from InDesign. E.g. by moving it through an automatic PDF workflow service for preparing PDFs for print…

 

Regards,
Uwe Laubender
( Adobe Community Expert )

Translate
LEGEND ,
Aug 31, 2023 Aug 31, 2023

Is it some kind of preparation / unification for the situation when Layers in PSD can be grouped into (sub)folders?

 

InDesign doesn't support Layer Groups ... for now? Is it a planned feature?

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Sep 01, 2023 Sep 01, 2023

In JavaScript this still (ID2023) works fine:

app.selection[0].graphics[0].graphicLayerOptions.graphicLayers.length

 

P.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Sep 01, 2023 Sep 01, 2023

But what number do you get - when your original INDD file had few layers before exporting to PDF?

 

I'm not talking it won't work - but it WILL return "1" for the 1st level layer with the "name" of the PDF file - but all layers are then nested as sub layers - not at the "top".

 

RobertTkaczyk_0-1693565449283.png

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Sep 01, 2023 Sep 01, 2023

but all layers are then nested as sub layers - not at the "top".

 

Not sure I understand this.

I have an indd with several layers and an image placed. Then when I export that indd and place the PDF in a new indd, the script line returns 1.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Sep 01, 2023 Sep 01, 2023

Exactly - please check my screenshot - PDF in the middle - "layer" name - 1st on the list - is the name of the placed PDF - and then laers are nested below.

 

Layers in the linked PSD - Image - last group on the screenshot - are exactly as in the linked PSD file.

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Sep 01, 2023 Sep 01, 2023

Layer structure of the placed PDF:

RobertTkaczyk_0-1693566176367.png

 

and PSD:

RobertTkaczyk_1-1693566242417.png

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Sep 01, 2023 Sep 01, 2023

Hi @Robert at ID-Tasker ,

as you can see from both apps there could be differences in the structure of the layers.

A PDF exported from InDesign is showing all layers as sub-layers of the main layer that holds the name of the InDesign document where the PDF was exported from. Nothing new with that. Other PDFs would not have that structure. Depending how the layers came into place, e.g. were directly added in Acrobat or other apps.

 

Regards,
Uwe Laubender
( Adobe Community Expert )

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Sep 01, 2023 Sep 01, 2023

So are you saying that this behavior / structure is ONLY for PDFs? 

 

It's possible that in the past I have been testing only PSD files... 

 


@Laubender wrote:

Hi @Robert at ID-Tasker ,

Other PDFs would not that structure. Depending how the layers came into place, e.g. were directly added in Acrobat or other apps.


 

I think something is missing in the first sentence - "would not have"? 

 

And the 2nd sentence - so this sub nesting is ONLY when PDF has been exported from InDesign? 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Sep 01, 2023 Sep 01, 2023

Ah yes. "have" was missing. Corrected that.

And also yes, this specific structure with the name of the InDesiogn document is from InDesign exported PDFs.

It could be totally different with other PDFs that e.g. were edited with Acrobat Pro. It could be also different if someone edited a PDF exported from InDesign. E.g. by moving it through an automatic PDF workflow service for preparing PDFs for print…

 

Regards,
Uwe Laubender
( Adobe Community Expert )

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Sep 01, 2023 Sep 01, 2023
LATEST

Great. Thanks for the clarification. 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines