# Can't change the base directory

**URL:** <https://discourse.jupyter.org/t/cant-change-the-base-directory/11585>\
**Category:** JupyterLab\
**Created:** [November 8, 2021, 2:15am UTC](https://discourse.jupyter.org/t/cant-change-the-base-directory/11585 "2021-11-08T02:15:52Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Wickdhub](https://yyz1.discourse-cdn.com/flex031/user_avatar/discourse.jupyter.org/wickdhub/32/5616_2.png) [@Wickdhub](https://discourse.jupyter.org/u/Wickdhub)\
**Post date:** [November 8, 2021, 2:15am UTC](https://discourse.jupyter.org/t/cant-change-the-base-directory/11585/1 "2021-11-08T02:15:52Z")

</div>

I want to open my .ipynb files with the jupyterlab desktop App, however when I change the configs of the jupyter\_lab\_config.py file to set the base directory to:  
`c.ServerApp.root_dir = 'C:/Users/Username/Desktop/'`,

it opens the app with the good home path, but it says: Directory not found  
Directory not found: “” and I can’t open my file directly with the app.

Do you know how I can fix this?

Edit: The same modification of the `jupyter_server_config.py` file works well with the jupyterlab in browser but not on the desktop app

Edit2: If I write `c.ServerApp.root_dir = 'C:\\Users\\Thomas\\Desktop'` I don’t get the message of error and it opens the file in the right directory but when I do open with, it opens the desktop directory with no file

Edit 3 I have test : `"C:/Users/Thomas/Desktop" 'C:/Users/Thomas/Desktop' "C:/Users/Thomas/Desktop/" 'C:/Users/Thomas/Desktop/' "C:\\Users\\Thomas\\Desktop" 'C:\\Users\\Thomas\\Desktop' "C:\\Users\\Thomas\\Desktop\\" 'C:\\Users\\Thomas\\Desktop\\' "C:\Users\Thomas\Desktop" 'C:\Users\Thomas\Desktop' "C:\Users\Thomas\Desktop\" 'C:\Users\Thomas\Desktop\' r"C:/Users/Thomas/Desktop" r'C:/Users/Thomas/Desktop' r"C:/Users/Thomas/Desktop/" r'C:/Users/Thomas/Desktop/' r"C:\\Users\\Thomas\\Desktop" r'C:\\Users\\Thomas\\Desktop' r"C:\\Users\\Thomas\\Desktop\\" r'C:\\Users\\Thomas\\Desktop\\' r"C:\Users\Thomas\Desktop" r'C:\Users\Thomas\Desktop' r"C:\Users\Thomas\Desktop\" r'C:\Users\Thomas\Desktop\'` some of them are just useless and open my file with the folder of the file, some of them open the path, but none of them allow me to open the file with the right home folder as I can do on the web browser

---

<div class="post-metadata">

**Author:** ![Wickdhub](https://yyz1.discourse-cdn.com/flex031/user_avatar/discourse.jupyter.org/wickdhub/32/5616_2.png) [@Wickdhub](https://discourse.jupyter.org/u/Wickdhub)\
**Post date:** [November 8, 2021, 4:37pm UTC](https://discourse.jupyter.org/t/cant-change-the-base-directory/11585/3 "2021-11-08T16:37:29Z")

</div>

Does anyone have an idea? Maybe I need to modify another file than `jupyter_lab_config.py`  
I don’t know if it is an official app so here is the link: [GitHub - jupyterlab/jupyterlab-desktop: JupyterLab desktop application, based on Electron.](https://github.com/jupyterlab/jupyterlab-desktop)

I wrote a little batch files that allow me to open the home dir to my desire directory and that open my file, however the PATH isn’t complete and I have to navigate to find it, it was better on web browser if you know how I can change that.

The batch file:  
`set PATH=C:\JupyterLab set DIR=C:\Users\Thomas\Desktop start "" %PATH%\JupyterLab.exe %DIR%^ %1`
