Share via


ChartColorFormat.SchemeColor Property

Returns or sets the color in the applied color scheme that's associated with the specified object. Read/write.

Namespace:  Microsoft.Office.Interop.PowerPoint
Assembly:  Microsoft.Office.Interop.PowerPoint (in Microsoft.Office.Interop.PowerPoint.dll)

Syntax

'Declaration
Property SchemeColor As Integer
    Get
    Set
'Usage
Dim instance As ChartColorFormat
Dim value As Integer

value = instance.SchemeColor

instance.SchemeColor = value
int SchemeColor { get; set; }

Property Value

Type: System.Int32
PpColorSchemeIndex

Remarks

The value of the SchemeColor property can be one of these PpColorSchemeIndex constants.

ppAccent1

ppAccent2

ppAccent3

ppBackground

ppFill

ppForeground

ppNotSchemeColor

ppSchemeColorMixed

ppShadow

ppTitle

Examples

This example switches the background color on slide one in the active presentation between an explicit red-green-blue value and the color-scheme background color.

With ActivePresentation.Slides(1)

    .FollowMasterBackground = False

    With .Background.Fill.ForeColor

        If .Type = msoColorTypeScheme Then

            .RGB = RGB(0, 128, 128)

        Else

            .SchemeColor= ppBackground

        End If

    End With

End With

See Also

Reference

ChartColorFormat Interface

ChartColorFormat Members

Microsoft.Office.Interop.PowerPoint Namespace