how to bind a command to the open button

S

susan

Hi,
Anybody knows how to bind a command to the open button at a file
browser dialog? I want to add selected files to a scrolllist.

Like this:

def browseFile(self):

file = askopenfilename(filetypes = [("TDF Files", "*.TDF"),
("All Files", "*.*")],multiple=1)

?.....

Thanks!
 
H

hg

susan said:
Hi,
Anybody knows how to bind a command to the open button at a file
browser dialog? I want to add selected files to a scrolllist.

Like this:

def browseFile(self):

file = askopenfilename(filetypes = [("TDF Files", "*.TDF"),
("All Files", "*.*")],multiple=1)

?.....

Thanks!

why don't you add the result "file" to the list ?
 
S

susan

Thank you very much, after I asked the question, I realized it has a
simple answer, exactly in your reply:)
hg said:
susan said:
Hi,
Anybody knows how to bind a command to the open button at a file
browser dialog? I want to add selected files to a scrolllist.

Like this:

def browseFile(self):

file = askopenfilename(filetypes = [("TDF Files", "*.TDF"),
("All Files", "*.*")],multiple=1)

?.....

Thanks!

why don't you add the result "file" to the list ?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top