[InDesign] Add Pantone color from book

I would like to add a Pantone color in InDesign from a Pantone Library, but I can’t get it to work.

The code from http://olivier.berquin.free.fr/indesign/indesign_2.html doesn’t work:

set myNewPantone to make color with properties {color value:{"PANTONE 2735 CV"}}

This code works:

set myNewColor to make color with properties {model:spot, space:CMYK, color value:{100, 95, 0, 3}, name:"PANTONE 2735 CV"}

But then I have to supply my own CMYK values, and I don’t want that.

Does anyone know how to add a swatch from a Pantone book in script similar to adding it in InDesign by hand?

Hi

I’m not near an indesign right now but if i were to guess then i would say you will need
the “load swatches” command then once there loaded, your first line of code might work.
Not 100% on this one as i can’t test.

Hope this helps though.