davidgohel / flextable

table farming
https://ardata-fr.github.io/flextable-book/
562 stars 81 forks source link

Unable to save flextable to pdf using save_as_image #522

Closed Pierre-GH closed 1 year ago

Pierre-GH commented 1 year ago

Hi David,

I was using the code below to save tables as pdf files. I have been using it without incident for a few weeks. Any help would be greatly appreciated. I have attached a copy of the error message from Adobe when opening the saved files. Thanks for the assist!

save_as_image(my_ft,path = "my_ft.pdf",zoom = 1,webshot = "webshot2")

image

davidgohel commented 1 year ago

yes, there have been lot of complaints about webshot and webshot2, so we decided to stop using it.

Now save_as_image() only use ragg and produce png and we are happy with this version.

If you want PDF, can't you use R Markdown (or Quarto)?

Pierre-GH commented 1 year ago

Many thanks for your assistance David. I am quite new to R and will need to learn how to use R Markdown for that purpose. I understand this issue has been closed, but I do have one more question. I was keen on this format largely due to preferences my employers. I am now using save_as_docx() and functions from your Officer package to achieve the same aim. The plan is to automate the script so it produces individualized reports for members of the team on a daily or monthly basis depending on data requirements. Do you know if that is possible using an R Markdown file? Can they be automated in the same was as scripts? I understand it can only work with R Scripts. Thanks David.

davidgohel commented 1 year ago

no problem @Pierre-GH

You can read here what I think about R Markdown / officer choice :) https://ardata-fr.github.io/officeverse/index.html#officer

github-actions[bot] commented 1 year ago

This old thread has been automatically locked. If you think you have found something related to this, please open a new issue and link to this old issue if necessary.