470,594 Members | 1,553 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,594 developers. It's quick & easy.

Tkinter Entry blocked by tkFileDialog


I have the following problem in Python 2.5 on Windows XP.
On Ubuntu I do not see the problem.

I have a Tkinter application as in the following example
The entry-widget is somehow blocked (i cannot type characters into it)
when I call askopenfilename before I create the widget.
Calling askopenfile again (by clicking the button) releases the block,
I can type into the entry as expected.

Could someone please try out the example and tell if you observe the
blocked entry, too?

Do you know a workaround? I want to call askopenfilename before
creating the widgets, since i use it to choose a config file which
controls the number and type of widgets I create.

import Tkinter
import tkFileDialog

tk = Tkinter.Tk()


Tkinter.Button(tk, text='ask', command=tkFileDialog.askopenfilename).grid()

Oct 2 '08 #1
0 1280

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Irmen de Jong | last post: by
5 posts views Thread by max(01)* | last post: by
5 posts views Thread by annagel | last post: by
1 post views Thread by Michael Yanowitz | last post: by
5 posts views Thread by vagrantbrad | last post: by
5 posts views Thread by half.italian | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.