Project

PSWriteOffice

PowerShell document automation across Word, Excel, PowerPoint, PDF, Reader, Confluence, Visio, and open text formats.

Stars 161
Forks 15
PowerShell Gallery downloads 158,661
Release v3.0.7
Language: C# Updated: 2026-09-19

API Reference

Cmdlet

Get-OfficeOneNote

Namespace PSWriteOffice
Inputs
System.String
Outputs
OfficeIMO.OneNote.OneNoteSection OfficeIMO.OneNote.OneNoteNotebook

Reads an offline OneNote section, notebook hierarchy, or packaged notebook.

Remarks

Reads an offline OneNote section, notebook hierarchy, or packaged notebook.

Examples

Authored help example

Read a OneNote section and inspect its pages.

PS>


$section = Get-OfficeOneNote -Path .\Operations.one
            $section.Pages | Select-Object Title, CreatedUtc, LastModifiedUtc
        

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.

Syntax

Get-OfficeOneNote [-NotebookOptions <OneNoteNotebookReaderOptions>] [-Options <OneNoteReaderOptions>] -Path <String> [<CommonParameters>]
#
Parameter set: All Parameter Sets

Parameters

NotebookOptions OneNoteNotebookReaderOptions optionalposition: namedpipeline: False
Notebook hierarchy, package, and section-error policy.
Options OneNoteReaderOptions optionalposition: namedpipeline: False
Bounded section and revision-store read options.
Path String requiredposition: 0pipeline: True (ByValue)aliases: FilePath
Path to a .one section, .onetoc2 notebook index, or .onepkg archive.

Outputs

OfficeIMO.OneNote.OneNoteSection, OfficeIMO.OneNote.OneNoteNotebook