Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

how to set the working directory in R

Hello,

 

I would like to set my working directory to a directory located on a server.  The address look like this one:

\\corporative\data\....\test

 

I have tried the following script

work_dir <-"\\corporative\data\....\test"

setwd(work_dir)

 

I receive this error: 

 

Capture20190806.PNG

 

1 ACCEPTED SOLUTION
v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @Anonymous ,

From the document, it says that when setting the working directory within the R script, you must define a full path to the working directory, rather than a relative path.

Please check if your path is correct.

Best  Regards,

Cherry

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @Anonymous ,

From the document, it says that when setting the working directory within the R script, you must define a full path to the working directory, rather than a relative path.

Please check if your path is correct.

Best  Regards,

Cherry

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.