SetCMYK Method

Sets color components in CMYK format.

Applies to: Color object, ColorEntry object

Syntax

object.SetCMYK (cyan, magenta, yellow, black)

The SetCMYK method syntax has these parts:

Part Description
object Required. An expression that returns an instance of an object in the Applies to list.
cyan Required. An expression that returns àn Integer value (from 0 to 100).
magenta Required. An expression that returns àn Integer value (from 0 to 100).
yellow Required. An expression that returns àn Integer value (from 0 to 100).
black Required. An expression that returns àn Integer value (from 0 to 100).

Remarks

After the SetCMYK method has been called, the color is converted to the CMYK format regardless of its previous format.

Example

This example demonstrates how to change the fill color of a rectanlge in CMYK format.

dim s as shape

' Create a Shape object
s = thisDoc.ActivePage.DrawRect(100,100,1000,1000) s.FillColor.SetCMYK(33,25,66,5) ' Change the Shape's fill color in CMYK format s.PropertyChanged(CDPT_FILLCOLOR)

 

See Also

SetRGB Method