Auto update

Ciao a tutti

Una cortesia e curiosit.
Ho creati un app Windows con Delle listbox che visualizzano Delle info in un database MySQL.
Vorrei che si aggiornassero in automatico alla variazione dei dati del database o a tempi ben precisi.

Come posso fare.
Grazie in anticipo

From Google Translate:

Add a Timer to the window that periodically repeats the query, matches the incoming records to the Listbox rows, and updates the ones needed. If there are a lot of rows, do this in reasonable chunks.

If you want to get fancy, use some Orm mechanism to convert the records to objects and store those objects in the Listbox RowTags. Implement the Listbox’s CellTextPaint to pull the information from the object for display on refresh. If you do that, you can pull the data in the background and the Listbox will update with a simple Invalidate.

DeepL translation: :wink:

[quote]Hi everyone

A courtesy and curiosity.
I created a Windows app with Listboxes that display info in a MySQL database.
I would like them to be updated automatically to the variation of the database data or at very specific times.

How can I do it.
Thanks in advance[/quote]