0

I'm trying to convert an existing swatch in InDesign to a new colour with AppleScript, and I'm finding it rather tough.

I'm getting an error code, thus:

error "Adobe InDesign CS5.5 got an error: Can’t set color of swatch \"CLIENT1\" of document id 12 to {0, 100, 100, 5}." number -10006 from color of swatch "CLIENT1" of document id 12

The code I'm using to adjust the swatch is this:

set color of swatch "CLIENT1" to c1

Any help would be greatly appreciated. It's driving me crazy.

Cheers.

t56k
  • 6,769
  • 9
  • 52
  • 115

2 Answers2

0

This works in CS2 for a cmyk swatch:

set color value of swatch "CLIENT1" to {0, 20, 50, 10}

you have to set all 4 values. If it is an rgb swatch you'd only need 3 values.

0

Solved it! The solution, for anyone else looking, is this:

set color value of color "CLIENT1" to c1

Enjoy.

t56k
  • 6,769
  • 9
  • 52
  • 115