View Full Version : Can a rule control fill or line color for a container?

May 16th, 2012, 09:47 AM

Is there any way to use a javascript rule to control the color for the fill or border of a container in a data-driven fashion? By "data-driven" I mean being able to use a color specified in the data rather than picking from an already-existing color that was defined in the template.

Context -- we have clients who are doing mailings on behalf of partner companies. They would like to be able to specify, in data, a corporate color that would be used for some text and for some graphic backgrounds.

I can see how to use a rule to define a text color on the fly, but it appears that a rule can only set the fill and border color to a pre-defined color (i.e. referencing it by name) and cannot set a fill or border color to a CMYK value.

Any ideas?


Andy Shaw

May 17th, 2012, 12:46 PM
You can use a solid block character for the fill color as Dan describes here:

For text color you can use the function listed here for converting to CMYK colors on the fly:

I am not aware of any method to do outlines.