[1] Open Anaconda Navigator

Open Anaconda Navigator, click left Environments, and click Base (root)-> Open Terminal

[2] Input the instruction jupyter notebook –generate-config

Press Enter to pop up the config location.



Open the file with VS Code

[3] Modify line 261

Notebook_dir = ‘D:\code folder \jupyter_notebook’ The working directory must have the folder created in its location beforehand

[4] Run the program

To save the changes, click the Run button on the command line and enter:

jupyter notebook
Copy the code

Press Enter to pop up your Home in the browser



At this point, the working directory is set successfully.