Need help running hello.py from cmd.

1,146 views
Skip to first unread message

Dustin Hensly

unread,
Oct 2, 2013, 4:28:22 PM10/2/13
to python-g...@googlegroups.com
When I change directory and type in C:\google-python-exercises> python hello.py  , I get an "Access denied."  I don't know what to do.  

Dustin Hensly

unread,
Oct 2, 2013, 5:28:23 PM10/2/13
to python-g...@googlegroups.com
This is what I'm having a problem with in particular.  I downloaded Python27 and Notepad ++.  Both work fine.  I can get the python interpreter running in the cmd window.  I just don't know how to do the following that's in brackets.  As you can see, I'm new to all this and really want to learn.  Please help me with this simple task.  Thanks :)
[With Python installed, open a command prompt (Accessories > Command Prompt, or type 'cmd' into the run dialog). Cd to the google-python-exercises directory (from unzipping google-python-exercises.zip). You should be able to run the hello.py python program by typing "python" followed by "hello.py" (what you type is shown in bold):
C:\google-python-exercises> python hello.py
Hello World
C:\google-python-exercises> python hello.py Alice
Hello Alice]

Robert Mandić

unread,
Oct 2, 2013, 5:33:05 PM10/2/13
to python-g...@googlegroups.com
​Access denied means you don't have permissions to execute that script.
Right click and fix them.


--
You received this message because you are subscribed to the Google Groups "Python GCU Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python-gcu-for...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.



--
Lp, Robert

Dustin Hensly

unread,
Oct 2, 2013, 7:35:10 PM10/2/13
to python-g...@googlegroups.com
Thank you very much, sir, for the reply.

When I'm in the cmd program, I don't know where to "right click and fix them".  I assumed that you meant that I needed to run the cmd as an admin.  So I did and got a different error message:  "google-python-exercises" is not recognizable as an internal or external command, an operable program or a batch file."

Robert Mandić

unread,
Oct 3, 2013, 2:42:06 AM10/3/13
to python-g...@googlegroups.com

You're not executin correctly then. Provide us with a screenshot.

Message has been deleted

Dustin Hensly

unread,
Oct 3, 2013, 3:06:26 PM10/3/13
to python-g...@googlegroups.com

Dustin Hensly

unread,
Oct 3, 2013, 3:14:46 PM10/3/13
to python-g...@googlegroups.com



On Thursday, October 3, 2013 1:42:06 AM UTC-5, Robert Mandić wrote:
Message has been deleted

Robert Mandić

unread,
Oct 3, 2013, 3:55:13 PM10/3/13
to python-g...@googlegroups.com
Ehm.
You're not changing your directory as I can see.
You're trying to execude "google-python-exercises" which is a directory :D
Enter the directory first.

So:
cd c:\google-python-exercises\
python hello.py


On Thu, Oct 3, 2013 at 9:18 PM, Dustin Hensly <dahens...@gmail.com> wrote:
Here's an Environment Variable, Path:
C:\Program Files (x86)\AMD APP\bin\x86_64;C:\Program Files (x86)\AMD APP\bin\x86;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files\Microsoft\Web Platform Installer\;C:\Python27;C:\Python27\Tools\Scripts

I just want to say thanks again for the attention.  This stuff can be daunting to a neophyte :)


On Thursday, October 3, 2013 1:42:06 AM UTC-5, Robert Mandić wrote:



--
Lp, Robert

Dustin Hensly

unread,
Oct 3, 2013, 5:51:31 PM10/3/13
to python-g...@googlegroups.com

LOL

Sir, you are a SCHOLAR & a GENTLEMAN :)

Robert Mandić

unread,
Oct 4, 2013, 1:56:21 AM10/4/13
to python-g...@googlegroups.com

Heheh glad I could help:D

Reply all
Reply to author
Forward
0 new messages