On Tue, Sep 30, 2008 at 12:58 PM, Pierre Dagenais <[EMAIL PROTECTED]> wrote: > The file test.py is in I:\Python25\MyCode, > if I enter: > > C:\>Python25\MyCode\python25 test.py at the DOS prompt, everything works as > I would expect. > > However when I enter the same command from any other directory I get this > error: > > C:\>python test.py > python: can't open file 'test.py' : [Errno 2] No such file or directory > > I've set the environment variable pythonpath as > C:\>set pythonpath = C:\\Python25\\MyCode > what am I doing wrong, > Thank u for your help, > _______________________________________________ > Tutor maillist - Tutor@python.org > http://mail.python.org/mailman/listinfo/tutor >
You need to give the full path to your test.py file. PYTHONPATH sets the python library search path. -- Stand Fast, tjg. [Timothy Grant] _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor