Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Cmdlet

Add-OfficeMarkdownList

Aliases: MarkdownList
Module
PSWriteOffice
Aliases
MarkdownList
Inputs
OfficeIMO.Markdown.MarkdownDocument
Outputs
OfficeIMO.Markdown.MarkdownDocument

Adds a Markdown list.

Syntax

Add-OfficeMarkdownList
[-Items] <String[]>
[-Numbered]
[-PassThru]
[-Start <Int32>]
[<CommonParameters>]
#
Parameter set: Items
Add-OfficeMarkdownList
-Document <MarkdownDocument>
[-Items] <String[]>
[-Numbered]
[-PassThru]
[-Start <Int32>]
[<CommonParameters>]
#
Parameter set: DocumentItems
Add-OfficeMarkdownList
[-Content] <ScriptBlock>
-Document <MarkdownDocument>
[-Numbered]
[-PassThru]
[-Start <Int32>]
[<CommonParameters>]
#
Parameter set: DocumentContent
Add-OfficeMarkdownList
[-Content] <ScriptBlock>
[-Numbered]
[-PassThru]
[-Start <Int32>]
[<CommonParameters>]
#
Parameter set: Content

Examples

Add ordered and unordered lists to a report.

New-OfficeMarkdown -Path .\Plan.md {
    Add-OfficeMarkdownHeading -Level 2 -Text 'Priorities'
    Add-OfficeMarkdownList -Items 'PDF examples', 'PowerPoint layout', 'Word report polish'
    Add-OfficeMarkdownHeading -Level 2 -Text 'Release order'
    Add-OfficeMarkdownList -Items 'Validate artifacts', 'Generate docs', 'Publish release' -Numbered -Start 1
}

Appends bullet and ordered lists to the current Markdown document.

Parameters

-Items String[] requiredposition: 0sets: Items, DocumentItems
List items to add.
-Numbered SwitchParameter optional
Use an ordered list instead of bullets.
-PassThru SwitchParameter optional
Emit the Markdown document after appending the list.
-Start Int32 optional
Starting number for ordered lists.
-Document MarkdownDocument requiredpipeline: True (ByValue)sets: DocumentItems, DocumentContent
Markdown document to update outside the DSL context.
-Content ScriptBlock requiredposition: 0sets: DocumentContent, Content
List items composed with MarkdownListItem children.

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.