Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: python script  (Read 3321 times)

0 Members and 1 Guest are viewing this topic.

belen

  • Guest
python script
« on: May 02, 2011, 08:41:03 AM »
Hi
I don’t know anything about programming languages.  I’m trying to run a python script from the command line (./proc.py) and I get the following message “./proc.py is not recognized as an internal or external command, operable program or batch file.  What should I do?

Geek-9pm


    Mastermind
  • Geek After Dark
  • Thanked: 1026
    • Gekk9pm bnlog
  • Certifications: List
  • Computer: Specs
  • Experience: Expert
  • OS: Windows 10
Re: python script
« Reply #1 on: May 02, 2011, 10:16:16 AM »
Hi
I don’t know anything about programming languages.  I’m trying to run a python script from the command line (./proc.py) and I get the following message “./proc.py is not recognized as an internal or external command, operable program or batch file.  What should I do?
The command
./proc.py
will not work from the command line. It is not part of the set or programs or commands that *DOS knows about. A script has to be run from its interpreter.This rule applies not only to Python, but all scripting languages.
A Python interpreter suitable for DOS can be found at:
http://www.python.org/
The current production versions are Python 2.7.1 and Python 3.2.

Once you have a suitable version installed on your PC, you can invoke Python from the command line and pass the script as an argument. See the documentation for examples.
--------
*DOS, I mean the command line  in Windows. Everybody calls it DOS and the documentation is found under DOS on this forum.

Geek-9pm


    Mastermind
  • Geek After Dark
  • Thanked: 1026
    • Gekk9pm bnlog
  • Certifications: List
  • Computer: Specs
  • Experience: Expert
  • OS: Windows 10
Re: python script
« Reply #2 on: May 02, 2011, 11:22:00 AM »
Screen Shot of shell.