Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

SPOT to PROCESS: CS3-JS

New Here ,
Jan 28, 2010 Jan 28, 2010

Hi All,
How to convert all SPOT to PROCESS in swatch using CS3-JS?
Without changing the default swatches [Paper,Reg...]
Thanks in advance.
Sam

TOPICS
Scripting
932
Translate
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

correct answers 1 Correct answer

Contributor , Jan 28, 2010 Jan 28, 2010

Sam try  the below code to do that:


app.activeDocument.inks.everyItem().convertToProcess = true;


Regards,

Ramkumar .P

Translate
Contributor ,
Jan 28, 2010 Jan 28, 2010

Hi Sam,


Use the below code to conver:


SPOT to PROCESS:


app.activeDocument.swatches.itemByRange(4,app.activeDocument.swatches.length-1).model = 1886548851;


PROCESS to SPOT:


app.activeDocument.swatches.itemByRange(4,app.activeDocument.swatches.length-1).model = 1936748404;


Regards,

Ramkumar .P

Translate
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
New Here ,
Jan 28, 2010 Jan 28, 2010

Thanks Ramkumar.

But I need to convert all the spot to process in InkManager not in the swatch pallete.

Is there any way to do this???

Sam

Translate
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
Contributor ,
Jan 28, 2010 Jan 28, 2010

Sam try  the below code to do that:


app.activeDocument.inks.everyItem().convertToProcess = true;


Regards,

Ramkumar .P

Translate
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
New Here ,
Jan 29, 2010 Jan 29, 2010

thank you so much Ramkumar.

I need one more clarification: is there any method to delete the unused swatches???

Sam

Translate
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
Engaged ,
Jan 29, 2010 Jan 29, 2010

Hi Sam,

Use below code:

var unusedcolor = app.activeDocument.unusedSwatches;

var unusedcolorlen = unusedcolor.length;

for (a = unusedcolorlen-1; a >= 0; a--)

{

unusedcolor.remove();

}

Cheers,

Shonky

Translate
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
Contributor ,
Jan 29, 2010 Jan 29, 2010

try this Sam:


var mySW = app.activeDocument.unusedSwatches
for(i=mySW.length-1;i>=0;i--)
mySW.remove();


Regards,

Ramkumar .P

Translate
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
LEGEND ,
Jan 29, 2010 Jan 29, 2010
LATEST

Credit to Dirk Becker:

var u = app.activeDocument.unusedSwatches; while( u.length )

u.pop().remove();

Harbs

Translate
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