Project

PSWriteOffice

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

Stars 654
Forks 82
Open issues 1
Total downloads 4,320,051
Release OfficeIMO-v3.5.3
Language: C# Updated: 2026-11-03
Cmdlet

Add-OfficeWordFooter

Aliases: WordFooter
Module
PSWriteOffice
Aliases
WordFooter
Inputs
None

Adds content to a section footer.

Syntax

Add-OfficeWordFooter
[[-Content] <ScriptBlock>]
[-PassThru]
[-Type <Default|First|Even>]
[<CommonParameters>]
#
Parameter set: All Parameter Sets

Description

Creates or reuses the requested footer part (default/first/even) and runs the DSL script block inside it.

Examples

Append page numbers to the default footer.

Add-OfficeWordSection { Add-OfficeWordFooter { Add-OfficeWordPageNumber -IncludeTotalPages } }

Inserts a footer displaying “Page X of Y”.

Parameters

-Content ScriptBlock optionalposition: 0
DSL scriptblock executed within the footer context.
-PassThru SwitchParameter optional
Emit the object created or changed by the command.
-Type WordHeaderFooterType optional
The footer kind (Default/First/Even).
Possible values: Default, First, Even

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.