Cmdlet
New-OfficePowerPoint
Creates a themed presentation, returning a live document or saving a completed content block.
Syntax
New-OfficePowerPoint
[-Accent <OfficeColor>]
[-Author <String>]
[-ContinuationFormat <String>]
[-Date <DateTime>]
[-Force]
[-LayoutStrategy <ContentFirst| DesignFirst| Compact| VisualFirst>]
[-NoFooter]
[-NoSlideNumber]
[[-Path] <String>]
[-Purpose <String>]
[-Seed <String>]
[-SlideSize <Screen4x3| Screen16x9| Screen16x10>]
[-Style <Auto| FieldProof| EditorialCaseStudy| TechnicalMap| QuietAppendix>]
[-Template <String>]
[-Theme <OfficeThemeInput>]
[<CommonParameters>]#Parameter set:
LiveNew-OfficePowerPoint
[-Accent <OfficeColor>]
[-AllowLoss]
[-Author <String>]
[-Content] <ScriptBlock>
[-ContinuationFormat <String>]
[-Date <DateTime>]
[-Force]
[-LayoutStrategy <ContentFirst| DesignFirst| Compact| VisualFirst>]
[-NoFooter]
[-NoSlideNumber]
[-PassThru]
[-Password <SecureString>]
[-Path] <String>
[-Purpose <String>]
[-Seed <String>]
[-Show]
[-SlideSize <Screen4x3| Screen16x9| Screen16x10>]
[-Style <Auto| FieldProof| EditorialCaseStudy| TechnicalMap| QuietAppendix>]
[-Template <String>]
[-Theme <OfficeThemeInput>]
[<CommonParameters>]#Parameter set:
ContentDescription
Without a content block no file is written, including on disposal. With a block, publication is atomic and an existing file requires Force. A block failure leaves the destination unchanged.
Examples
Create a deck and return its saved file.
New-OfficePowerPoint -Path ./Status.pptx -Theme Modern -Author 'Operations team' -PassThru {
PowerPointSlide -Title 'Status update'
}Create a live document for explicit editing and saving.
$deck = New-OfficePowerPoint -Theme Boardroom
PowerPointSlide -Document $deck -Title 'Service review'
Save-OfficePowerPoint -Document $deck -Path ./Review.pptx
Close-OfficePowerPoint -Document $deckCreate a compact technical review using the dark theme.
New-OfficePowerPoint -Path ./Architecture.pptx -Theme Dark -Purpose 'technical proposal' -LayoutStrategy Compact {
PowerPointSlide -Title 'Architecture review'
PowerPointSlide -Title 'Decisions' { PowerPointList 'Retain the API boundary', 'Track rollout evidence' }
}Parameters
- -Accent OfficeColor
- Brand accent used to derive the theme's accent palette while retaining its fonts and surfaces.
- Author shown on title slides and written to the package's creator property.
- -ContinuationFormat String
- Continuation title format, with title, part and total supplied as {0}, {1} and {2}.
- -Date DateTime
- Date shown on title slides using the current culture's short date format.
- -Force SwitchParameter
- Allow the new document to replace an existing destination.
- -LayoutStrategy PowerPointAutoLayoutStrategy
- ContentFirst, DesignFirst, Compact or VisualFirst allocation; overrides the recipe's strategy.
- Possible values:
ContentFirst,DesignFirst,Compact,VisualFirst - Suppress footer text on every designed slide.
- -NoSlideNumber SwitchParameter
- Suppress slide numbers on every designed slide.
- -Path String
- Optional associated destination for a live document; required when a content block saves a file.
- -Purpose String
- Plain-language purpose matched by the native design brief to a built-in recipe.
- -Seed String
- Stable deck seed; an individual slide can supply its own seed.
- -SlideSize PowerPointSlideSizePreset
- Slide dimensions; copied templates retain their dimensions unless this parameter is supplied.
- Possible values:
Screen4x3,Screen16x9,Screen16x10 - -Style PowerPointDeckStyle
- Composition tuning layered on the theme; Auto uses the theme and purpose-matched recipe.
- Possible values:
Auto,FieldProof,EditorialCaseStudy,TechnicalMap,QuietAppendix - -Template String
- Existing presentation/template copied as starting content. Theme applies visual styling separately.
- -Theme OfficeThemeInput
- Built-in theme, theme object or a Word, Excel or PowerPoint document/template whose visual theme is read. Defaults to Modern.
- -AllowLoss SwitchParameter
- Explicitly accept reductions reported by the content block's native save.
- -Content ScriptBlock
- Authoring block to complete before the document is atomically saved and closed.
- -PassThru SwitchParameter
- Return the saved FileInfo after a completed content block.
- -Password SecureString
- Password for the saved file; plaintext input warns, and credentials contribute their password.
- -Show SwitchParameter
- Open the saved result in its registered application after the content block succeeds.
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.