Link SQLite database to a DataControl

I’m a beginner with Xojo and I have a issue with connecting (linking) a database to a DataControl.

After I have selected the database and the table for the DataControl in the Bahvior section and click with the mouse somewhere or press TAB my selection is deleted.

Also if I press CTRL-S immediatly the values for database and table are not saved.

What is my fault here?

It is highly suggested that you dispense with using the DataControl, and access the database directly via SQL statements. This will give you greater control over the management of your data, as well as having your code ready to convert to other databases, as well as if/when XOJO finally decides to drop that awful control.

Hello Dave,

thanks for reply - I see your point and agree! But as log as this is officially promoted also in the documentation I would see it to work, as I payed for this!

So if I’m doing somethig wrong I will correct it, but if it is a bug, than XOJO should fix it.

Take a look at the example included with Xojo here:


With that said, DataControl is extremely simplistic. Beyond using it for simple examples like this, it doesn’t have much practical purpose.

I never liked the DataControl. It can do a few things, but as soon as you have other needs, you have to write your own.

Hello Paul,

I have used this example as a reference and started to write a very simple test application.

It doesn’t work as described in my case, as I’m simply not able to link the database to the DataControl.