Hi everyone,
Im new to python and im trying to make sure my path is set correctly. I completed a program and save it but cant seem to make it run in cmd, it keep saying that it cannot find file or directory. Please help
3 1327
Hi everyone,
Im new to python and im trying to make sure my path is set correctly. I completed a program and save it but cant seem to make it run in cmd, it keep saying that it cannot find file or directory. Please help
Give details of the command that you're typing. Have configured python correctly and added it to your path?
Hi everyone,
Im new to python and im trying to make sure my path is set correctly. I completed a program and save it but cant seem to make it run in cmd, it keep saying that it cannot find file or directory. Please help
In Windows, if you need to add the Python directory to your PATH environment variable, right click My Computer, pull down to Properties. On the Advanced tab click Environment variables. If there is a PATH variable there, select it and click edit, otherwise click new and name the new variable "PATH". INSERT something like "C:\python24;" (what ever is right for your system) at the beginning of the semicolon-separated list. Click OK and dismiss all the dialog boxes. At the command-line (cmd), you must either cd (change directory) to the folder where you .py file is located or type in the complete path. ie
C:\Python Scripts>python myPythonScript.py.
Hope that helps.
In Windows, if you need to add the Python directory to your PATH environment variable, right click My Computer, pull down to Properties. On the Advanced tab click Environment variables. If there is a PATH variable there, select it and click edit, otherwise click new and name the new variable "PATH". INSERT something like "C:\python24;" (what ever is right for your system) at the beginning of the semicolon-separated list. Click OK and dismiss all the dialog boxes. At the command-line (cmd), you must either cd (change directory) to the folder where you .py file is located or type in the complete path. ie
C:\Python Scripts>python myPythonScript.py.
Hope that helps.
That said, there are much easier ways to run your script. One example: Python comes with a workable IDE called IDLE that lets you edit you .py files and run them from the menu.
Sign in to post your reply or Sign up for a free account.
Similar topics
by: Prawdziwa Blondynka |
last post by:
Hi,
I would like to do the following with C++ and Xerces:
set the schema path in an XML file to parse in this way:
XMLCh* schemaLocation = XMLString::transcode(namespaceAndPath);...
|
by: Steve Yerkes |
last post by:
There seems to be way too much confusion over how to set focus on the a field using a field validator. I looked all over the web and found people trying to do this, but not getting anywhere. There...
|
by: Wolfgang Kaml |
last post by:
I am not sure if this is more of an expert question, but I am sure that they
are out there.
I'd like to setup a general application or bin directory on my Win2003.Net
Server that will hold some...
|
by: Ralph |
last post by:
Hi,
I've done a bit of reading on setting up an Isolated .NET environment for
each of my developers. We all run Windows XP Pro, IIS and have local
instances of SQL Server for development.
I...
|
by: Patrick |
last post by:
I am dynamically creating TextArea and drop-down lists in ASP.NET using
something like HtmlTextArea eachTextArea = new HtmlTextArea();
I tried to set the "name" of these TextAreas, etc. (e.g....
|
by: David Lozzi |
last post by:
Howdy,
I have a user control that is a report to display data. On the page the
control is inserted in, I have filter options to filter the report. When I
try to do something like this, nothing...
|
by: Johan |
last post by:
Hi
I'm using WMI to set and remove folderpermissions and it sems to work
fine, sometimes. I start by having the folderpermissons manuly set to
Everyone and Everone has full rights. When I'm...
|
by: phil campaigne |
last post by:
On Mon, 1 Mar 2004, phil campaigne wrote:
>> Nigel J. Andrews wrote:
>>
>
>
>>> >On Mon, 1 Mar 2004, Phil Campaigne wrote:
>>> >
>>> >
|
by: laredotornado |
last post by:
Hi,
I'm using PHP 4.4.4 on Apache 2 on Fedora Core 5. PHP was installed
using Apache's apxs and the php library was installed to
/usr/local/php. However, when I set my "error_reporting"...
|
by: bart.hernalsteen |
last post by:
Hi,
I want to read the envorinment setting "path" and then on certain
conditions change this setting.
ex path : "%SystemRoot%\system32;%SystemRoot%;%SystemRoot%
\System32\Wbem;C:\Program...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new...
| |