# Set-OfficePdfTheme

Applies an OfficeIMO.Pdf theme preset to a generated PDF document.

Project

PSWriteOffice

PowerShell document automation across OfficeIMO's document, spreadsheet, presentation, PDF, Project, Access, EPUB, invoicing, and conversion engines.

[View on GitHub](https://github.com/EvotecIT/OfficeIMO/tree/master/PowerShell/PSWriteOffice) [Visit Website](#) [Releases](https://github.com/EvotecIT/PSWriteOffice/releases/tag/v3.0.5) [Changelog](#) [Get package](https://www.powershellgallery.com/packages/PSWriteOffice/0.2.0)

Stars **725**

Forks **84**

Open issues **3**

Total downloads **5,231,343**

Release **OfficeIMO-v3.6.2**

Language: C# Updated: 2026-11-23

Cmdlet 

Aliases: PdfTheme

**Module**

`PSWriteOffice`

**Aliases**

`PdfTheme`

**Inputs**

`OfficeIMO.Pdf.PdfDocument`

**Outputs**

`OfficeIMO.Pdf.PdfDocument`

**Source**

[SetOfficePdfThemeCommand.cs:25](https://github.com/EvotecIT/PSWriteOffice/blob/main/Sources/PSWriteOffice/Cmdlets/Pdf/SetOfficePdfThemeCommand.cs#L25) 

Applies an OfficeIMO.Pdf theme preset to a generated PDF document.

## Syntax

```
Set-OfficePdfTheme
[-PassThru]
[-Theme] <WordLike|TechnicalDocument|Compact|Report>
[<CommonParameters>]
```

[#](#method-set-officepdftheme-switchparameter-officepdfthemepreset)

Parameter set: `Context`

```
Set-OfficePdfTheme
-Document <PdfDocument>
[-PassThru]
[-Theme] <WordLike|TechnicalDocument|Compact|Report>
[<CommonParameters>]
```

[#](#method-set-officepdftheme-pdfdocument-switchparameter-officepdfthemepreset)

Parameter set: `Document`

## Description

Themes provide a reusable visual baseline for generated PDFs. They are OfficeIMO.Pdf presets, exposed by PSWriteOffice as simple enum values. Apply a theme near the start of a New-OfficePdf script block so later content inherits the intended report rhythm.

## Examples

### Apply the report theme.

```powershell
New-OfficePdf -Path .\Report.pdf {
  PdfTheme Report
  PdfHeading 'Service Review'
  PdfParagraph 'The report theme defines a polished baseline.'
}
```

Uses the PDF report theme for generated content.

## Parameters

**-PassThru SwitchParameter optional**

Emit the updated document.

**-Theme OfficePdfThemePreset requiredposition: 0**

Theme preset to apply.

Possible values: `WordLike`, `TechnicalDocument`, `Compact`, `Report`

**-Document PdfDocument requiredpipeline: True (ByValue)sets: Document**

Compatibility parameter. Page composition is supported only inside New-OfficePdf.

## Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see [about_CommonParameters](https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_commonparameters).

Evotec API Reference Copyright 2026 Evotec Services

<!-- PowerForge markdown artifact sha256:BF7A4FE04DF0EF7242465BB50CAAA2CC62C55924DD653281BA14506A74916EDB -->
