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-OfficeMarkdownImage

Aliases: MarkdownImage
Module
PSWriteOffice
Aliases
MarkdownImage
Inputs
OfficeIMO.Markdown.MarkdownDoc
Outputs
OfficeIMO.Markdown.MarkdownDoc

Adds a Markdown image.

Syntax

Add-OfficeMarkdownImage
[-Alt <String>]
[-Height <Double>]
[-PassThru]
[-Path] <String>
[-Title <String>]
[-Width <Double>]
[<CommonParameters>]
#
Parameter set: Context
Add-OfficeMarkdownImage
[-Alt <String>]
-Document <MarkdownDoc>
[-Height <Double>]
[-PassThru]
[-Path] <String>
[-Title <String>]
[-Width <Double>]
[<CommonParameters>]
#
Parameter set: Document

Examples

Add a report image with alt text and sizing.

New-OfficeMarkdown -Path .\Report.md {
    Add-OfficeMarkdownHeading -Level 2 -Text 'Architecture'
    Add-OfficeMarkdownImage -Path '.\Assets\architecture.png' -Alt 'Architecture diagram' -Title 'Current architecture' -Width 640
}

Appends an image block with accessibility text and optional presentation metadata.

Parameters

-Alt String optional
Alt text for the image.
-Height Double optional
Optional height in pixels.
-PassThru SwitchParameter optional
Emit the Markdown document after appending the image.
-Path String requiredposition: 0
Image path or URL.
-Title String optional
Optional title for the image.
-Width Double optional
Optional width in pixels.
-Document MarkdownDoc requiredpipeline: True (ByValue)sets: Document
Markdown document to update outside the DSL context.

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.