Creating Lab SPOT color swatch

Explorer ,
May 08, 2022 May 08, 2022

Copy link to clipboard

Copied

Hello Everyone,

 

I have to create the SPOT color swatch with the Lab values. Also drafted the script, but it showing some error while running and unable to figure out the problem with my Script.

Please help me to overcome this issue, and also attaching the script.

 

docRef = app.activeDocument;
var color12 = new LabColor();
color12.l = 17;
color12.a = 1;
color12.b = 3;
var spot = docRef.spots.add();
spot.name = "PANTONE Black C";
spot.colorType = ColorModel.SPOT;
spot.color = color12;

 

 

 

TOPICS
Scripting

Views

139

Likes

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
Advocate ,
May 08, 2022 May 08, 2022

Copy link to clipboard

Copied

It's working fine for me.  What error message are you getting? 

Likes

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
Adobe Community Professional ,
May 08, 2022 May 08, 2022

Copy link to clipboard

Copied

LATEST

Worked for me too.

Windows 10, AI 26.2.1

 

Questions:

Is this to create a single swatch or will you expand the script to add a number of them at once?

Are you using this swatch for actual spot-color printing or for CMYK conversion?

David Creamer
Adobe Certified Instructor, Adobe Certified Professional, and Adobe Certified Expert (since 1995)

Likes

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