Highlighted

ID script: move page without deleting it afterwards

New Here ,
Jul 15, 2020

Copy link to clipboard

Copied

 

Hello,
i am looking for a solution to move a page via script without deleting it from the source. In the dialog this is possible by checking the checkbox if it is not activated.
How is this possible via script?
I have to use the move function and not duplicate or copy, otherwise the layout will not be placed correctly in the target.
Here is my example but I could not find the checkbox option in the documentation.
sourcePage.move(LocationOptions.AFTER, destDocument.pages[0]);

 

MELAF_0-1594809801439.png

 

Adobe Community Professional
Correct answer by Manan Joshi | Adobe Community Professional

Use duplicate method, it should do what you want

Page duplicate ([to:LocationOptions=LocationOptions], reference:Varies Page Spread)

Duplicates the page.

Parameter

Type

Description

to

LocationOptions

LocationOptions.AFTER

LocationOptions.AT_BEGINNING

LocationOptions.AT_END

LocationOptions.BEFORE

LocationOptions.UNKNOWN

The location at which to place the duplicate page relative to the reference object or within the document or spread. (Optional)

(default: LocationOptions.AT_END)

reference

Page

Spread

The reference object. Note: Required when the to value specifies before or after. Can accept: Page or Spread. (Optional)

 

-Manan

TOPICS
How to, Scripting

Views

50

Likes

Translate

Translate

Report

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

ID script: move page without deleting it afterwards

New Here ,
Jul 15, 2020

Copy link to clipboard

Copied

 

Hello,
i am looking for a solution to move a page via script without deleting it from the source. In the dialog this is possible by checking the checkbox if it is not activated.
How is this possible via script?
I have to use the move function and not duplicate or copy, otherwise the layout will not be placed correctly in the target.
Here is my example but I could not find the checkbox option in the documentation.
sourcePage.move(LocationOptions.AFTER, destDocument.pages[0]);

 

MELAF_0-1594809801439.png

 

Adobe Community Professional
Correct answer by Manan Joshi | Adobe Community Professional

Use duplicate method, it should do what you want

Page duplicate ([to:LocationOptions=LocationOptions], reference:Varies Page Spread)

Duplicates the page.

Parameter

Type

Description

to

LocationOptions

LocationOptions.AFTER

LocationOptions.AT_BEGINNING

LocationOptions.AT_END

LocationOptions.BEFORE

LocationOptions.UNKNOWN

The location at which to place the duplicate page relative to the reference object or within the document or spread. (Optional)

(default: LocationOptions.AT_END)

reference

Page

Spread

The reference object. Note: Required when the to value specifies before or after. Can accept: Page or Spread. (Optional)

 

-Manan

TOPICS
How to, Scripting

Views

51

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jul 15, 2020 0
Adobe Community Professional ,
Jul 15, 2020

Copy link to clipboard

Copied

Use duplicate method, it should do what you want

Page duplicate ([to:LocationOptions=LocationOptions], reference:Varies Page Spread)

Duplicates the page.

Parameter

Type

Description

to

LocationOptions

LocationOptions.AFTER

LocationOptions.AT_BEGINNING

LocationOptions.AT_END

LocationOptions.BEFORE

LocationOptions.UNKNOWN

The location at which to place the duplicate page relative to the reference object or within the document or spread. (Optional)

(default: LocationOptions.AT_END)

reference

Page

Spread

The reference object. Note: Required when the to value specifies before or after. Can accept: Page or Spread. (Optional)

 

-Manan

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 15, 2020 1