Francis Lavoie wrote:
I have a problem in windows 2k with python and libglade.

when I import libglade and I start the program, I receive this error :

/N:\python\test\pContact>python pCon
Traceback (most recent call last):
 File "pContact.py", line 3, in ?
   import gtk
   import libglade
ImportError: No module named glade
/

I installed the GTK developpement package, I copy the file in the libglade zip file into the python directory Lib
(from http://gladewin32.sourceforge.net/)
I set the python path in my path var.


If there any document/tutorial/hint to help me, that will be appreciated

1. Remove all previous installations of GTK+ and pygtk. That means GTK+ from gladewin32, dropline, Dev-Cpp, gimp, gaim, you name it... Then carefully look in Windows\system32 for any GTK+-related leftover DLLs, in particular iconv.dll, libintl.dll, libxml2.dll, intl-1.dll and all the libg*.dll and g*.dll with a GTK+ name (gobject, gthread, atk, pango,...)


2. Install the GTK+ runtime from gladewin32


http://prdownloads.sourceforge.net/gladewin32/gtk-win32-2.4.14-rc1.exe?download


Make sure that the "Register environment variable" is selected (this should be the default)


3. Run the Gtk-demo (Start menu/Gtk/Gtk-demo). Does it work ? If no, please post the error message in this thread.

4. Try to run a simple helloworld example http://www.pcpm.ucl.ac.be/~gustin/win32_ports/binaries/helloworld.zip
Unzip helloworld.exe and double-click on it (no need to open a console). Does it work ? If no, please post the error message in this thread.


5. Install pygtk-2.4

http://www.pcpm.ucl.ac.be/~gustin/win32_ports/

6. From python (command line, python ide, pythonwin), try "import pygtk" and "import gtk"

7. Download the pygtk tarball http://ftp.gnome.org/pub/GNOME/sources/pygtk/2.4/pygtk-2.4.1.tar.gz
Untar it and try to run examples/pygtk-demo/pygtk-demo.py. It should work out of the box. Report any problem.


In a regular installation, only steps 2 and 5 should be required. i have tested that config on 20+ machines without any problem.

Cedric
_______________________________________________
pygtk mailing list   [email protected]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/

Reply via email to