update or refresh a Listbox widget

A

Arne Meissner

Hello!

Is there a function to update/refresh a listbox widget.
My one is connected to a database and after a change of the database I would
like the listbox to be updated.

Thank you for your help!
Arne
 
F

Fredrik Lundh

Arne said:
Is there a function to update/refresh a listbox widget.
My one is connected to a database and after a change of the database I would
like the listbox to be updated.

Tkinter?

the quickest way is to do:

w.delete(0, END)
w.insert(0, *data)

where w is the widget and data is a list (or other sequence) containing
the new data.

</F>
 

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

Forum statistics

Threads
474,291
Messages
2,571,493
Members
48,162
Latest member
DarwinMaku

Latest Threads

Top