Copy link to clipboard
Copied
In illustrator scripting how to change color mode RGB to CMYK expect:
I used the below code, its running for active document. when i run the bacth .eps file. The below code is not working.
app.executeMenuCommand("doc-color-cmyk");
best answer much appreciated.
Copy link to clipboard
Copied
This code works fine to me
I hope works for you too
var doc=app.activeDocument;
if (doc.documentColorSpace == "DocumentColorSpace.RGB") {
app.executeMenuCommand('doc-color-cmyk');
alert("Changed to CMYK");
};
Copy link to clipboard
Copied
Hi Gersson
Thank you for your replay.I tried this one but this is not work perfectly.when run in illustrator script panel.
if any other way pls suggest.
thanks
Copy link to clipboard
Copied
could you please provide the file you need to change to CMYK space
Copy link to clipboard
Copied
Hi Gersson,
File not possible to upload.
Copy link to clipboard
Copied
Hi,
Could you please share your code so that we can look how you are using the above statement.
Copy link to clipboard
Copied
Hi charu,
Thanks for your replay.pls find below code.
app.executeMenuCommand("selectall");
app.executeMenuCommand("Colors7");
app.executeMenuCommand('doc-color-cmyk');
Copy link to clipboard
Copied
The code that you shared is running perfectly fine, but as you mentioned you run in the batch, we would like to see complete code. If we just talk amount single command it is working fine. If possible please share your all steps of batch process and some example eps file. You can upload those sample files and share the link with us.