tags:

views:

95

answers:

1

Hello,

link text

When I do :

tkMessageBox.askquestion(title="Symbol Display",message="Is the symbol visible on the console")

along with Symbol Display window tk window is also coming.

If i press "Yes"...the child window return yes,whereas tk window remains there.

Whenever I am tryng to close tk window, End Program - tk comes. on pushing "End Now" button "pythonw.exe" window comes asking to send error report or not.

Why is it so ? How can I avoid tk window from popping out without affecting my script execution ???

+2  A: 

The trick is to invoke withdraw on the Tk root top-level:

>>> import tkMessageBox, Tkinter
>>> Tkinter.Tk().withdraw()
>>> tkMessageBox.askquestion(
...     title="Symbol Display",
...     message="Is the symbol visible on the console")
krawyoti