setting the active doc and adding page numbers

Explorer ,
Dec 13, 2018 Dec 13, 2018

Copy link to clipboard

Copied

var openDoc = app.openDoc({cPath: myPath});

var d = app.activeDocs; <--gets all open docs

app.alert("this.path: " + this.path);  <--this.path is not always the openDoc. 

app.alert("openDoc.path: " + openDoc.path);

How do I make the openDoc the active Doc?  Essentially I am needing to add page numbers to it.

TOPICS
Acrobat SDK and JavaScript

Views

59

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
community guidelines

correct answers 1 Correct Answer

Adobe Community Professional , Dec 13, 2018 Dec 13, 2018
You can try using the bringToFront method, but there's really no need to do it. Just use the openDoc variable instead of the "this" variable.

Likes

Translate

Translate
Adobe Community Professional ,
Dec 13, 2018 Dec 13, 2018

Copy link to clipboard

Copied

LATEST

You can try using the bringToFront method, but there's really no need to do it. Just use the openDoc variable instead of the "this" variable.

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
community guidelines