fgColor Property

Microsoft FrontPage Visual Basic

fgColor Property

Sets or returns a String, specifying a color name or red-green-blue (RGB) value, that represents the foreground (or text) color of the document.

expression.fgColor

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

Remarks

The fgColor property sets the value of the text attribute for the BODY element.

For more information about setting colors, see the HTML Color Table.

Example

The following example changes the font color of the specified document to the color specified in the strColor argument.

    Sub ChangeTextColor(objDoc As FPHTMLDocument, strColor As String)
    objDoc.fgColor = strColor
End Sub
  

Use the following example to call the preceding subroutine.

    Sub CallChangeTextColor()
    Call ChangeTextColor(ActiveDocument, "#663399")
End Sub