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

"Open Recent" topmost file as part of an action

Engaged ,
Jan 17, 2023 Jan 17, 2023

Copy link to clipboard

Copied

Is it possible to open the top most file under "Open Recent" files, as part of an Action? But not locked to a particular file when the Action was created, but is actually the most recent file opened.

 

The reason I want to do this is because there seems no other way to do what I want. A couple of years ago I asked about a certain action that I need, and there was no solution, so I'll try again.

 

I have about 30 actions that save images in a variable format and size, e.g. jpg 1080P, or PSD 1920W (1920 wide), and so on. These files are destined for Premiere, but the original file I want to save as Tiff > Zip just before I run the relevant Action.

 

The problem is… Tiff > Zip can take up to a minute to save, whereas Tiff > LZW usually takes only seconds, meaning I can jump straight into Premiere to see the result, instead of waiting for the Tiff > Zip file to save.

 

These are the typical steps I take when using an Action:

  1. The file is edited.
  2. I save the file as LZW – fast
  3. I run the Action
  4. I open Premiere and the file is already updated.

 

I want to generate new Actions that, right at the end (after the jpg or whatever has been saved), that the most recent file is then opened (the same file I was working on) and automatically saved and closed as Tiff > Zip. i.e. it runs in the background while I'm inside Premiere looking for the next file to edit.

 

My Actions can be downloaded here. It's only the ones starting with "Crop" that I'm talking about. To see how they work, you have to have a selection in place before the Action is run.

 

Thanks in advance for any suggestions.

 

 

 

 

TOPICS
Actions and scripting

Views

248

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

Community Expert , Jan 18, 2023 Jan 18, 2023

@Guy Burns 

 

The following "action helper script" will open the most recent file. It can be recorded into an action as a step.

 

#target photoshop
if (app.recentFiles.length > 0) {
    try {
        app.open(File(app.recentFiles[0]));
    } catch (e) {
        //alert("The file is missing or an unexpected error occurred!"
    }
} else {
    //alert("The Open Recent list is empty!");
}

 

Votes

Translate

Translate
Adobe
Community Expert ,
Jan 18, 2023 Jan 18, 2023

Copy link to clipboard

Copied

@Guy Burns 

 

The following "action helper script" will open the most recent file. It can be recorded into an action as a step.

 

#target photoshop
if (app.recentFiles.length > 0) {
    try {
        app.open(File(app.recentFiles[0]));
    } catch (e) {
        //alert("The file is missing or an unexpected error occurred!"
    }
} else {
    //alert("The Open Recent list is empty!");
}

 

Votes

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
Community Expert ,
Jan 19, 2023 Jan 19, 2023

Copy link to clipboard

Copied

LATEST

@Guy Burns 

 

So how did the script go for you?

Votes

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