About 302,000 results
Open links in new tab
  1. windows - Python - How do you run a .py file? - Stack Overflow

    Feb 29, 2012 · Since you seem to be on windows you can do this so python <filename.py>. Check that python's bin folder is in your PATH, or you can do c:\python23\bin\python …

  2. How to execute a file within the Python interpreter?

    Jun 22, 2009 · I'm trying to execute a file with Python commands from within the interpreter. I'm trying to use variables and settings from that file, not to invoke a separate process.

  3. How to run a Python file in Visual Studio code from the terminal?

    Nov 28, 2022 · Open the folder using VS Code: File -> Open Folder Create your script and save it in the folder Open a new terminal: Terminal -> New Terminal Type the command: python …

  4. How to execute Python scripts in Windows? - Stack Overflow

    Found an incredibly useful answer here: How to run different python versions in cmd? I would suggest using the Python Launcher for Windows utility that introduced was into Python 3.3 a …

  5. How to run a .py file in windows command line? - Stack Overflow

    Nov 5, 2013 · Imagine I have a .py file in directory mentioned above and I want to run it in windows commandline, but I can't. How can I do it?

  6. komodo ide - How do I run a Python program? - Stack Overflow

    The command py -3 file.py always works for me, and if I want to run Python 2 code, as long as Python 2 is in my path, just changing the command to py -2 file.py works perfectly.

  7. Scheduling a .py file on Task Scheduler in Windows 10

    Suppose the script you want to run is E:\My script.py. Instead of running the script directly, instruct the task scheduler to run python.exe with the script as an argument. For example: …

  8. Creating a BAT file for python script - Stack Overflow

    Jan 1, 2011 · How can I create a simple BAT file that will run my python script located at C:\\somescript.py?

  9. run python script directly from command line - Stack Overflow

    from the command line, as long as you have Python installed and on your path environment variable (i.e. set to run with python, which, if installed, would typically be the case).

  10. Running a python script via Powershell script - Stack Overflow

    Jan 24, 2019 · I have a python script which I can run via PowerShell using the following code: cd User\\PythonScripts python TestFile.py Now I want to run these simple commands via a …