CommentsColor Property

Microsoft Word Visual Basic

Show All

CommentsColor Property

       

Returns or sets a WdColorIndex constant that represents the color of comments in a document. Read/write.

WdColorIndex can be one of these WdColorIndex constants.
wdAuto
wdBlack
wdBlue
wdBrightGreen
wdByAuthor
wdDarkBlue
wdDarkRed
wdDarkYellow
wdGray25
wdGray50
wdGreen
wdNoHighlight
wdPink
wdRed
wdTeal
wdTurquoise
wdViolet
wdWhite
wdYellow

expression.CommentsColor

expression   Required. An expression that returns one of the objects in the Applies To list.

Example

This example sets the global option for Microsoft Word to color comments made in documents according to the author of the comment.

Sub ColorCodeComments()
    Options.CommentsColor = wdByAuthor
End Sub