Closed AnnaBurn closed 6 years ago
Dear Anna
This should help:
library(officer)
library(flextable)
library(magrittr)
ft <- regulartable(head(mtcars))
doc <- read_docx() %>%
body_add_par("centered text", style = "centered") %>%
body_bookmark("val_to_replace") %>%
body_add_par("A title", style = "heading 1") %>%
body_add_par("Hello world!", style = "Normal") %>%
cursor_bookmark("val_to_replace") %>%
body_add_flextable(value = ft, pos = "on")
print(doc, target = tempfile(fileext = ".docx")) %>% browseURL()
Issue moved to davidgohel/flextable #81 via ZenHub
Hi,
I am loving the flextable and OfficeR packages, but it would be really useful to have a body_replace_flextable_at_bkm() as I often need to include tables in my final reports. Is this a feature that will be coming soon?