将文件从R保存到SharePoint文件夹

将文件从R保存到SharePoint文件夹,r,sharepoint,shiny-server,R,Sharepoint,Shiny Server,我能够从Rshiny服务器上运行的R打开SharePoint文件夹中的文件。但是,无法将文件保存到同一文件夹。我得到如下所示的错误消息。我尝试了这里和这里提供的解决方案,但没有成功。有什么建议吗 df <- read.csv("http://sites.somecompany.com/sites/sitename/Documents/UserDocumentFolder/filename.csv") write.csv(df, "http://sites.somecompany.com/

我能够从Rshiny服务器上运行的R打开SharePoint文件夹中的文件。但是,无法将文件保存到同一文件夹。我得到如下所示的错误消息。我尝试了这里和这里提供的解决方案,但没有成功。有什么建议吗

df <- read.csv("http://sites.somecompany.com/sites/sitename/Documents/UserDocumentFolder/filename.csv")

write.csv(df, "http://sites.somecompany.com/sites/sitename/Documents/UserDocumentFolder/filename2.csv")

can only open URLs for readingError in file(file, ifelse(append, "a", "w")) : 
  cannot open the connection

df我尝试了这个,它成功了:

system("curl --ntlm --user username:password --upload-file someFolder/FileToCopy.ext https://sites.somecompany.com/sites/sitename/Documents/UserDocumentFolder/FileToCopy.ext")

我正在尝试使用这种方法,但似乎无法使其工作。你愿意帮我解决这个问题吗?或者你有别的方法我可以试试吗?当然!让我知道我能帮什么忙。太棒了!我问了一个新问题。我不确定哪里出了问题,但我猜url中的某些内容不太正确。如果你能快速查看一下,看看你是否发现了一个错误,那就太好了