Cmdlet
New-OfficeHtmlWordOptions
Creates native HTML-to-Word options for Convert-OfficeDocument.
Syntax
New-OfficeHtmlWordOptions
[-BasePath <String>]
[-ContinueNumbering]
[-Font <String>]
[-IncludeListStyles]
[-RenderPreAsTable]
[-SectionTagHandling <WordSection| Block>]
[-StylesheetContent <String[]>]
[-StylesheetPath <String[]>]
[-SupportsHeadingNumbering]
[-TableCaptionPosition <Above| Below>]
[<CommonParameters>]#Parameter set:
DefaultExamples
Apply an explicit stylesheet while keeping document-linked stylesheets disabled.
$options = New-OfficeHtmlWordOptions -StylesheetPath ./report.css -RenderPreAsTable
Convert-OfficeDocument -Path ./Report.html -To Word -OutputPath ./Report.docx -Options $optionsParameters
- -BasePath String
- Filesystem base folder for relative resources, without creating it.
- -ContinueNumbering SwitchParameter
- Continue numbering across imported lists.
- -Font String
- Font family for imported text.
- -IncludeListStyles SwitchParameter
- Import list style information.
- -RenderPreAsTable SwitchParameter
- Render preformatted blocks inside a single-cell table.
- -SectionTagHandling WordHtmlSectionTagHandling
- How HTML section tags map into Word.
- Possible values:
WordSection,Block - -StylesheetContent String[]
- Additional CSS stylesheet text.
- -StylesheetPath String[]
- Explicit literal stylesheet files, resolved through the FileSystem provider.
- -SupportsHeadingNumbering SwitchParameter
- Allow heading numbering during import.
- -TableCaptionPosition WordHtmlTableCaptionPosition
- Position of an imported table caption.
- Possible values:
Above,Below
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.