Share via


_Master.ApplyTheme Method

Applies a theme or design template to the specified slide master, title master, handout master, notes master, or design master.

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

Syntax

'Declaration
Sub ApplyTheme ( _
    themeName As String _
)
'Usage
Dim instance As _Master
Dim themeName As String

instance.ApplyTheme(themeName)
void ApplyTheme(
    string themeName
)

Parameters

  • themeName
    Type: System.String
    The path and name of the theme file (.thmx) or design template file (.pot) to apply to the Master object.

Examples

This example applies a saved theme to a slide master:

ActivePresentation.SlideMaster.ApplyTheme"C:\Program Files\Microsoft Office\Templates\MyTheme.thmx"

This example applies a saved design template to a slide master:

ActivePresentation.SlideMaster.ApplyTheme"C:\Program Files\Microsoft Office\Templates\MyTheme.pot"

See Also

Reference

_Master Interface

_Master Members

Microsoft.Office.Interop.PowerPoint Namespace