Well it took a bit longer because I was trying to do this without using a macro. Unfortunately HSQLDB embedded is quite old and doesn’t have anything near what I was looking for. Maybe another database using an array in a field (such as PostgreSQL) but even there will require some more research and testing.
Instead went with a very short macro. Took your form and moved the list box to a separate internal form.
For the list box properties, on the
General tab, the
List Entries stayed the same. On the
Data tab, the matching
List content entries are the
in portions of the SQL. Example:
( "Intervenções" IN ( 'A', 'B', 'C') )
Now when a item is selected in the list box, the
Item status changed event is fired off and the macro moves the selected
in statement from the list box to the filter of the form with the actual data table. The form is refreshed to display the selection and the form is cleared for when the form is opened on the next occasion.
Sample ------- Amostra.odb
Just a note, I can conceive of the list being in its own table and having the list box get the list from the table instead of the individual entries int the list box.