Highlighted

Trying to change the active page

Explorer ,
Mar 03, 2017

Copy link to clipboard

Copied

Hello world!    

     I have an infuriatingly simple issue. Javascript. I am trying to figure out how to set the current active window to a specific hard coded page on a specific hard coded document so I can switch to a page, make selections and modifications on the page then switch to the next page, and reiterate through an entire document all through script without user interaction being necessary. I have tried a number of things but I just cant find any information on this online. Please help!!!

app.activeDocument.layoutWindows[0].activePage = app.activeDocument.pages[0];

TOPICS
Scripting

Views

969

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

Trying to change the active page

Explorer ,
Mar 03, 2017

Copy link to clipboard

Copied

Hello world!    

     I have an infuriatingly simple issue. Javascript. I am trying to figure out how to set the current active window to a specific hard coded page on a specific hard coded document so I can switch to a page, make selections and modifications on the page then switch to the next page, and reiterate through an entire document all through script without user interaction being necessary. I have tried a number of things but I just cant find any information on this online. Please help!!!

app.activeDocument.layoutWindows[0].activePage = app.activeDocument.pages[0];

TOPICS
Scripting

Views

970

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
Mar 03, 2017 0
Valorous Hero ,
Mar 03, 2017

Copy link to clipboard

Copied

app.activeDocument.layoutWindows[0].activePage = app.activeDocument.pages[0];

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...
Mar 03, 2017 3
Explorer ,
Mar 03, 2017

Copy link to clipboard

Copied

Thank you so much for the quick and correct response!

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...
Mar 03, 2017 0
Community Beginner ,
Jun 20, 2020

Copy link to clipboard

Copied

Thanks for this - do you know if there's anyway to wait for this to happen? I've changing contents of items on the activePage but sometimes the switch to a new active page is a little delayed and it starts overwriting on the same page for a while

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...
Jun 20, 2020 0