2017-08-29 154 views
0

我能夠從運行在Rshiny服務器上的R的SharePoint文件夾中打開文件。但是,無法將文件保存到同一文件夾。我收到如下所示的錯誤消息。我嘗試了這裏提供的解決方案Saving a file to Sharepoint with R,這裏Copying file to sharepoint library in R沒有運氣。有什麼建議麼?將文件從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 

回答

0

我想這和它的工作:

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