Writing to unmapped windows share from R

What would be the best practice to write directly to an unmapped Windows share from R?
(Or to back up a step, is this possible?)

I need to run a scheduled script (user not logged in) and write to a remote computer within our Windows domain.

I've tried various versions of

write_csv(bob,  "//server/share/bob.csv")

without success.

I can add mapping the drive to the batch file that will call the R script, and have R write to that drive, but wanted to learn if it was possible to do this directly from R and can't find good documentation. (I've seen some try xxxxx stuff, but that did not seem to work for me.

Bonus question: If this is possible, is it possible for admin shares? In other words, something like \mydomain\mycomputername\c$\folder.

Thank you smart people of the world!

if mapping the drive is something you know how to do from your Windows command line, and your user has access to use the command line then you can use R's system2() function to send a command to windows OS

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.