Bagikan melalui


ChartColorFormat.RGB Property (Word)

Returns the red-green-blue value of the specified color. Read-only Long.

Version Information

Version Added: Word 2007

Syntax

expression .RGB

expression A variable that represents a ChartColorFormat object.

Example

The following example enables up and down bars, then adds a criss-cross pattern to the down bars and sets the pattern color to the chart area foreground fill color, for the first chart group of the first chart in the active document.

With ActiveDocument.InlineShapes(1) 
 If .HasChart Then 
 With .Chart 
 .ChartGroups(1).HasUpDownBars = True 
 .ChartGroups(1).DownBars.Interior.Pattern = xlPatternCrissCross 
 .ChartGroups(1).DownBars.Interior.PatternColor = _ 
 .ChartArea.Fill.ForeColor.RGB 
 End With 
 End If 
End With

See Also

Concepts

ChartColorFormat Object Members

ChartColorFormat Object