Skip to content
This repository has been archived by the owner on Apr 12, 2022. It is now read-only.

Commit

Permalink
Added WorkBookmarks
Browse files Browse the repository at this point in the history
  • Loading branch information
PrzemyslawKlys committed Mar 21, 2020
1 parent eebde91 commit 9149c84
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Public/Get-WordBookmark.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
function Get-WordBookmark {
[cmdletBinding()]
param(
[parameter(ValueFromPipelineByPropertyName, ValueFromPipeline)][Xceed.Document.NET.Container] $WordDocument
)
$WordDocument.Bookmarks | Select-Object -Property Name, Paragraph
}
8 changes: 8 additions & 0 deletions Public/Set-WordBookmark.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
function Set-WordBookmark {
[cmdletBinding()]
param(
[string] $BookmarkName,
[string] $BookmarkText
)
$WordDocument.InsertAtBookmark($BookmarkText, $BookmarkName)
}
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ _PSWriteWord_ is PowerShell module to create Microsoft Word documents without Mi

- 1.1.4 - Unreleased
- Fixes for New-WordList
- Added Get-WordBookmark
- Added Set-WordBookmark

- 1.1.3 - 18.01.2020
- Fixes for Colors for Documentimo
Expand Down

0 comments on commit 9149c84

Please sign in to comment.