Highlighted

Script or action to make last opened document the active document

New Here ,
Oct 26, 2020

Copy link to clipboard

Copied

I have an action which resizes and sharpens an image. It then runs a script which imports the layers from another open document (Watermark1600.psd)

After the script has run, the active document is always Watermark1600.psd, however I want it to be the last opened or previously active image (i.e. the image that has just been resized, sharpened and had the layers imported.)

 

I have Googled using a few connotations searching for what I want, to no avail.

 

Any help appreciated, thank you.

TOPICS
Actions and scripting

Views

38

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

Script or action to make last opened document the active document

New Here ,
Oct 26, 2020

Copy link to clipboard

Copied

I have an action which resizes and sharpens an image. It then runs a script which imports the layers from another open document (Watermark1600.psd)

After the script has run, the active document is always Watermark1600.psd, however I want it to be the last opened or previously active image (i.e. the image that has just been resized, sharpened and had the layers imported.)

 

I have Googled using a few connotations searching for what I want, to no avail.

 

Any help appreciated, thank you.

TOPICS
Actions and scripting

Views

39

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
Oct 26, 2020 0
r-bin LATEST
Adobe Community Professional ,
Oct 26, 2020

Copy link to clipboard

Copied

In the script, do the first command.
var act_doc = app.activeDocumnet;

The last
app.activeDocument = act_doc;
 

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...
Oct 26, 2020 2