Python Forum
How to change directory to any folder where python is not installed ?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to change directory to any folder where python is not installed ?
#1
Hello everyone,
I am using Python3.6.3 on a Windows OS
what i would like know after searching and not finding the right answer on google, how to make the directory in any folder? to explain more:
I usually start the cmd then type cd C:\Python3.6.3 and enter to load python
but if i try to save any file using python code, this file will be saved in "C:\Python3.6.3" ! I don't want that ! what i want for example to save the file on desktop in a folder let's say called "pythonProjects"
so how can i do that when my python is installed in the C:\Python3.6.3 folder ?

Thanks in advance :)
Reply
#2
You have to add directory containing python.exe to system environment variable PATH. Then you can call python from every place you want.
Reply
#3
(Apr-03-2020, 10:07 AM)Mateusz Wrote: You have to add directory containing python.exe to system environment variable PATH. Then you can call python from every place you want.

thanks Mateusz for your reply, I assume the problem is with the Path variable because I added it manually
I will reinstall python and make it automatic
Reply
#4
Here is a install tutorial,longer down in Thread also how to fix/add environment variable Path after install.
Python 3.8 (3.6-3.7) and pip installation under Windows
Reply
#5
(Apr-03-2020, 10:42 AM)snippsat Wrote: Here is a install tutorial,longer down in Thread also how to fix/add environment variable Path after install.
Python 3.8 (3.6-3.7) and pip installation under Windows

thank you snippsat
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
Question How to add Python folder in Windows Registry ? Touktouk 1 250 Feb-20-2024, 01:04 PM
Last Post: DeaD_EyE
  Python Launcher (on Windows) only necessary when 2 or more Python versions installed? pstein 1 317 Feb-17-2024, 12:43 PM
Last Post: deanhystad
  Compare folder A and subfolder B and display files that are in folder A but not in su Melcu54 3 533 Jan-05-2024, 05:16 PM
Last Post: Pedroski55
  change directory of save of python files akbarza 3 876 Jul-23-2023, 08:30 AM
Last Post: Gribouillis
  python gzip all files from a folder mg24 3 3,985 Oct-28-2022, 03:59 PM
Last Post: mg24
  Make a python folder .exe Extra 0 1,028 Jun-10-2022, 01:20 AM
Last Post: Extra
  Compare filename with folder name and copy matching files into a particular folder shantanu97 2 4,475 Dec-18-2021, 09:32 PM
Last Post: Larz60+
  Installed versions of Python SamHobbs 5 2,506 Sep-02-2021, 02:28 PM
Last Post: jefsummers
  Move file from one folder to another folder with timestamp added end of file shantanu97 0 2,470 Mar-22-2021, 10:59 AM
Last Post: shantanu97
  I seem to have two versions of python 3.7.9 installed miner_tom 7 4,436 Nov-22-2020, 06:42 PM
Last Post: miner_tom

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020