docx_bookmarks: List Word bookmarks

Description Usage Arguments See Also Examples

View source: R/read_docx.R

Description

List bookmarks id that can be found in a Word document.

Usage

1

Arguments

x

an rdocx object

See Also

Other functions for Word document informations: doc_properties(), docx_dim(), length.rdocx(), set_doc_properties(), styles_info()

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
library(officer)

doc_1 <- read_docx()
doc_1 <- body_add_par(doc_1, "centered text", style = "centered")
doc_1 <- body_bookmark(doc_1, "text_to_replace_1")
doc_1 <- body_add_par(doc_1, "centered text", style = "centered")
doc_1 <- body_bookmark(doc_1, "text_to_replace_2")

docx_bookmarks(doc_1)

docx_bookmarks(read_docx())

Example output

[1] "text_to_replace_1" "text_to_replace_2"
character(0)

officer documentation built on July 21, 2021, 5:07 p.m.