tkFileDialog -> ImportError: No module named shell

Mike Driscoll kyosohma at gmail.com
Mon Apr 13 14:28:19 EDT 2009


On Apr 13, 11:26 am, Alan G Isaac <alan.is... at gmail.com> wrote:
> Why do I get the ImportError below?
> What is the right way to do this?
> Thanks,
> Alan Isaac
>
> Python 2.5.4 (r254:67916, Dec 23 2008, 15:10:54) [MSC v.1310 32 bit (Intel)] on win32
> Type "help", "copyright", "credits" or "license" for more information.
>  >>> import Tkinter as tk
>  >>> root=tk.Tk()
>  >>> import tkFileDialog
>  >>> fh = tkFileDialog.asksaveasfile()
> Traceback (most recent call last):
>    File "boot_com_servers.py", line 44, in <module>
>    File "tbzr.pyo", line 125, in <module>
>    File "tbzr.pyo", line 60, in get_all_com_classes
>    File "contextmenu.pyo", line 9, in <module>
> ImportError: No module named shell
> Redirecting output to win32trace remote collector

Well, if you have tortoisehg installed, uninstall it. That was what
was giving me this exact error with wxPython file dialogs.

Mike



More information about the Python-list mailing list