Illustrator Newbie Colours question
Illustrator Newbie Colours question
- Subject: Illustrator Newbie Colours question
- From: Mark Settle <email@hidden>
- Date: Tue, 11 Mar 2003 12:51:45 +0000
Morning all - I9m new to this Applescripting lark and so far it9s been a
mixture of great joy when it works and immense frustration when it doesn9t.
Here9s my current problem.
I9m wanting to automate the creating and updating of an artwork panel
showing client/job details and colour blocks. I9ve cracked updating the info
from a Filemaker Pro database and creating spot colours in my Illustrator 10
file but what9s vexing me is colouring up items with the newly created
colours in my swatch. The tint blocks are in the form of a named group
consisting of 6 tint squares and 2 items of text. Usually I can select the
group manually in Illustrator and hit the new spot colour in my swatch and
the whole thing recolours maintaining the tints.
Here9s a script I wrote for testing purposes:
tell application "Adobe Illustrator 10"
set newdoc to make new document
set NewSpot to make new spot in document 1 with properties {color
type:spot color, name:"PANTONE Whatever", color:{cyan:100.0, magenta:100.0,
yellow:0.0, black:0.0}}
make new rectangle in newdoc with properties {name:"Rect"}
set selection of document 1 to {page item "Rect" of document 1}
set fill color of path item "Rect" to spot of newdoc whose name is
"PANTONE Whatever"
end tell
It gets as far as selecting the rectangle but then gives me the following
error -
3Adobe Illustrator 10 got an error: Can't set fill color of path item "Rect"
to spot of document 1 whose name = "PANTONE Whatever".
Depending on the script, I can also get 3wrong type2 errors as well.
It9s got to be something simple but it9s driving me mad. All I want to be
able to do is colour up items, whether they be text, paths or groups with a
named spot colour swatch. Can anybody point me in the right direction?
Thanks in advance
Mark
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.