Skip to main content
Participant
November 27, 2019
Question

Photoshop CC Automated Actions Fail

  • November 27, 2019
  • 6 replies
  • 2240 views

I recorded a simple action to convert folders of images to CMYK, the action goes as follows:

 

1. convert to CMYK

2. save

3. close out of file

 

I use this action on a daily basis to convert large batches of images, and after upgrading to the latest update it no longer works. I get an error saying "Convert mode is not currently available". Yet if I manually do these steps to each image, it works just fine.

This topic has been closed for replies.

6 replies

Kevin Stohlmeyer
Community Expert
Community Expert
November 17, 2020

Have you tried re-recording the action from scratch?

Karmalakas
Known Participant
November 17, 2020

I know this is an old thread, but I'm trying to learn scripting for Ps and also getting exact same message


Ps v22.0.1 on Win10
My script is:

var doc = app.activeDocument;
var indexedDoc = doc.duplicate('_tmpIndexed', true);


var indexedOptions = new IndexedConversionOptions();
indexedOptions.colors = 7;
/*indexedOptions.palette = Palette.LOCALSELECTIVE;
indexedOptions.forced = ForcedColors.NONE;
indexedOptions.transparency = false;
indexedOptions.dither = Dither.NONE;*/

indexedDoc.changeMode(ChangeMode.INDEXEDCOLOR, indexedOptions);


 Any insight?

Stephen Marsh
Community Expert
Community Expert
November 17, 2020

Just a guess, but is the doc in any other mode than RGB?

Karmalakas
Known Participant
November 17, 2020

It's AdobeRGB. Tried with RGB JPEG and your guess is valid - it does the thing. But how do I convert from AdobeRGB then? Executing

indexedDoc.changeMode(ChangeMode.RGB);

before INDEXEDCOLOR doesn't help 😞

Stephen Marsh
Community Expert
Community Expert
November 27, 2019

I modified the following script to do the same thing as your action/batch (convert to working CMYK and overwrite the original files, it is presumed that the input file formats are capable of being saved as CMYK):

 

 

 

//forums.adobe.com/thread/2593940
//forums.adobe.com/message/10926314#10926314
#target photoshop  
var inFolder = Folder.selectDialog("Select the input folder", "");
var inFiles = inFolder.getFiles();
app.displayDialogs = DialogModes.NO;

for (var a = 0; a < inFiles.length; a++) {
    try {
        var inDoc = open(inFiles[a]);
        inDoc.changeMode(ChangeMode.CMYK);
        inDoc.save();
        inDoc.close();
    } catch (e) {
        continue;
    }
};
alert("Input files converted to working space CMYK and saved with embedded ICC profile");

 

 

 

https://prepression.blogspot.com/2017/11/downloading-and-installing-adobe-scripts.html

Stephen Marsh
Community Expert
Community Expert
November 27, 2019

If your action does not have an open command step, you should not use the "override action open..." checkbox in the Batch interface.

Bojan Živković11378569
Community Expert
Community Expert
November 27, 2019

I can not reproduce problem without more informations. Which version of Photoshop you are using? I am on Win running 21.0.1 version. Can you post screenshot with error message and Convert Mode step in action expanded. 

Participant
November 27, 2019

Same version sadly, and I can't get it to work. I still have last year's release on my mac and it works just fine which leads me to believe this is an issue with the new update. I've attached screenshots of the issue.

Bojan Živković11378569
Community Expert
Community Expert
November 27, 2019

So the problem is when running Batch script, otherwise it works when playing action on its own? Can you upload action somewhere to test it?

November 27, 2019

Moving to the Photoshop forum from Community Help