Using Tkinter in windows 98

Fredrik Lundh fredrik at pythonware.com
Sun May 30 11:23:24 EDT 1999


Dennis Wilson <lincwils at teleport.com> wrote:
> My question is what does python throw into the mix? This has to be the
> breaking point, if my windows works and my tcl/tk works.

not sure your attitude works, though.

...

but alright, here's the full story:

the Tcl installer puts the DLL's in the same directory as the
EXE files.  since Windows searches in the EXE directory be-
fore it looks in any other directory, Tcl works even if you
don't have the Tcl executables in the PATH.

however, Python cannot find it, unless you do one of the
following:

    -- put a copy of the Tcl/Tk DLL's in the
    python.exe directory.    you'll find the
    DLL's in "\program files\tcl\bin" (if you're
    doing this on a non-US platform, you
    may have to change "program files" to
    something else.

    -- add the Tcl bin directory to the PATH
    (by editing autoexec.bat).  according to
    some reports, you have to use the "short
    form" of the directory name; typically
    "c:\progra~1\tcl\bin" (use "dir" to figure
    out what this is on your box).
    
    -- put a copy of the Tcl/Tk DLL's in the
    \windows\system directory (this directory
    is always in the path).  if on NT, use
    \winnt\system32 instead.

(given that only some people stumble upon this problem, I
suspect the Tcl/Tk installer, or some earlier version of it,
does something like this under certain circumstances. I
don't use it myself, so I don't really care).

and yes, if Tkinter complains about missing library files,
place a copy of the Tcl/Tk lib directory at ..\lib (relative
to the Python bin directory, that is).

or set the TCL_LIBRARY and TK_LIBRARY environment
variables.  or edit the registry.

...

btw, you could have figured this out yourself through
http://www.python.org/search/

</F>





More information about the Python-list mailing list