Skip to main content
bfrankphoto
Inspiring
March 21, 2017
Answered

InDesign Script to Convert All Colors to Process CMYK

  • March 21, 2017
  • 3 replies
  • 7123 views

I regularly do prepress work for large projects that will have RGB colors and/or spot colors. These documents should have been designed only using process CMYK, but hey, designers are designers, so I need to fix them. I know I can convert manually in the palette or via ink manager, but was wondering if anyone has a script that will do that for me on an open, active indesign document. That would be so much quicker as I can just run that as a default on all documents.

Thanks.

Correct answer Anantha Prabu G

Hi,

Try tis code:

var myDoc = app.activeDocument;

app.activeDocument.colors.everyItem().properties = {space:ColorSpace.CMYK};

app.activeDocument.colors.everyItem().properties = {space:ColorSpace.CMYK, model:ColorModel.PROCESS};

3 replies

Participant
July 18, 2020

Hi Ananth2,
First of all thanks for the scripts, it was working great uptill the 2020 version came in, i tries to fiddel things around, but no luck, can there be a similar script for indesign 2020 version ?

rob day
Community Expert
Community Expert
July 18, 2020

You don’t really need a script—select all of the swatches and set the Color Type and Color Mode to change all.

 

Inspiring
June 30, 2019

Hi, I would like to have a modified version of this.
I need to have everything converted to CMYK, leaving PMS spots untouched. I just need to get rid of RGBs and Labs via scripting. Is it possible?

The thing arises from an issue I have in a specific document. The publisher is using an automated proprietary "Q-checker" plugin to verify the document, and the plugin says this document "does not contain only CMYK or SPOT colors" meaning there's something hidden that is still in RGB or Lab. Thing is, it's not a linked file, because Indesign's own preflight function won't find anything. I also already tried to use the swatches palette to add unnamed colors, but nothing comes up. I'm at a loss.

It may be a locked, invisible object in a group, almost certainly anchored in text. It's thousands of these and I can't check them all by hand.

Thanks.

Willi Adelberger
Community Expert
Community Expert
July 18, 2020

If images have RGB images, even with spot coloros, the correct way is to keep them in RGB and never convert them before exporting the INDD file to a PDF.

 

Anantha Prabu G
Anantha Prabu GCorrect answer
Legend
March 21, 2017

Hi,

Try tis code:

var myDoc = app.activeDocument;

app.activeDocument.colors.everyItem().properties = {space:ColorSpace.CMYK};

app.activeDocument.colors.everyItem().properties = {space:ColorSpace.CMYK, model:ColorModel.PROCESS};

Thanks,PrabuDesign smarter, faster, and bolder with InDesign scripting.
bfrankphoto
Inspiring
March 22, 2017

Just to clarify, since  don't write script, is this JS or apple script?

Anantha Prabu G
Legend
March 22, 2017

Hi,

This is JavaScript..

Thanks,PrabuDesign smarter, faster, and bolder with InDesign scripting.