On Sat, Nov 28, 2009 at 3:21 PM, Mikey3D <[email protected]> wrote:

> Windows 7:
>
> My project is in: C:\Python26\Lib\site-packages\mysite
>
> I'm working on this section: Playing with the API
> http://docs.djangoproject.com/en/dev/intro/tutorial01/#playing-with-the-api
>
> When I do (Windows+R >cmd >OK) to do python shell (python manage.py
> shell) it works. But I have try other tool that come with Python26 is
> IDLE (Python GUI) and I get an error:


I think what you need is the following before you import anything from
Django: (or any module that imports from Django):

import os
os.environ['DJANGO_SETTINGS_MODULE'] = "settings"

(The absolute or relative path to your settings file.)

Nick

--

You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.


Reply via email to