On Fri, 21 Apr 2006 08:41:19 +0100
Casey Wong Kam Shun <[EMAIL PROTECTED]> wrote:
> First of all thanks for your reply in the Tkinter-discuss forum. I am using
> the TkinterDnD for a project of mine. I have the newest tkdnd
> installed in the newest Tcl\lib folder (activestate Tcl, it is installed in
> c:\Tcl), and I have followed the instruction to copy the TkinterDnD folder
> into the Python*\lib\site-packages folder. I am using Xp pro sp2 and
> python 2.2.3. I have also put the tkdnd unzipped folder into the
> python22\tcl folder. I would appreciate it if you could let me know what
> could have caused the following error when I run the dnddemo.py:
>
>
> TclError Exception in Tk callback
> Function: <function runScriptCommand at 0x019CA610> (type: <type
> 'function'>)
> Args: ()
> Traceback (innermost last):
> File "C:\Program Files\Leo\extensions\Pmw\Pmw_1_2\lib\PmwBase.py", line
> 1752, in __call__
> return apply(self.func, args)
> File "C:\Program Files\Leo\plugins\mod_scripting.py", line 333, in
> runScriptCommand
> c.executeScript(c.currentPosition(),useSelectedText=True,silent=True)
> File "C:\Program Files\Leo\src\leoCommands.py", line 1316, in
> executeScript
> exec script in d
> File "<string>", line 8, in ?
> None
> File "C:\Program Files\Visual Components\Python
> 2.2\Lib\site-packages\TkinterDnD\TkinterDnD.py", line 352, in __init__
> self.TkdndVersion = _require(self)
> File "C:\Program Files\Visual Components\Python
> 2.2\Lib\site-packages\TkinterDnD\TkinterDnD.py", line 333, in _require
> tkdndver = tkroot.tk.call('package', 'require', 'tkdnd')
> TclError: can't find package tkdnd
>
Hi Casey,
this is obviously a Tcl problem, Tcl still cannot find tkdnd.
I just tried and downloaded libtkdnd10.zip from sourceforge, which seems to be
the latest windows binary,
and it did not work for me either (not sure if this is the same as you have, it
contains only
a single dll file).
I have also tried an older version (tkdnd-1.0a2) which "works" partially, i.e.
the demo windows
appear, however drag and drop does not work. I think the difference is that
this one contains a pkgIndex.tcl
file which was missing from the other release. Maybe the problem here was that
it is compiled against a different
version of Tk than mine (on linux however the precompiled binary works well
with different version of Tcl/Tk).
A "desperate" try might be to install snackAmp
(<http://snackamp.sourceforge.net>) which comes with tkdnd (at least the linux
version)
and see if you can copy the tkdnd libs from there into your python installation
(I have not tried this though).
Maybe one of the Tcl gurus here knows more than me.
If no one from tkinter-discuss can help maybe you should contact the author or
try on a tcl forum.
Sorry
Michael
_______________________________________________
Tkinter-discuss mailing list
[email protected]
http://mail.python.org/mailman/listinfo/tkinter-discuss