[Tutor] newbie question

Daniel Yoo dyoo@hkn.eecs.berkeley.edu
Fri, 24 Nov 2000 12:21:29 -0800 (PST)


On Fri, 24 Nov 2000, john smith smith wrote:

> Can someone explain to me how to set the python path in windows98,cause no
> one in my neck of the woods seems to be sure.I have more confidence in you
> guys anyway.Ive been following the tutorials but it seems i can't import any
> of my own modules if i don't have the path.please help.

Sure; it sounds like you'll want to set up your PYTHONPATH to point to a
directory that you have saved your modules.  To do this, add a line in
C:\autoexec.bat that says something like:

    SET PYTHONPATH=.;C:\python-2.0\Lib;C:\mymodules;

That period in the beginning makes sure that the current directory is also
accessible for module imports.  You can indicate several paths --- just
separate them with semicolons.

Finally, you may need to restart your computer to reload PYTHONPATH
settings: your system looks at autoexec.bat on system reboots.

Hope this helps!