我正在尝试通过 R 在 Excel 的页面设置中编辑第一个页码
library(RDCOMClient)
xlApp <- COMCreate("Excel.Application")
xlApp[["Visible"]] <- TRUE
xlBook <- xlApp[["Workbooks"]]$Add()
xlSheet <- xlBook[["Worksheets"]]$Item(1)
xlSheet$PageSetup()$FirstPageNumber() <- 1
xlSheet$PageSetup()$FirstPageNumber() <- 1 中的错误:赋值左侧无效 (NULL)