How to make listbox and detail

I’m very new to Xojo/RB. I want to make a screen with one listbox on the leftside (filled with data from my database) and next to the listbox some textfields with the detailed data chosen from the listbox.

I can make the listbox work. But I can’t get the data in the textfields. I saw several video’s and have read three different books (Real basic) but I can’t find a good tutorial for it. I some books and video’s I saw an easy method for databinding (shift click listbox and textfield) but I can’t find this tool anymore in Xojo.

I think the best way is to do it in code. So if any one can help me, I would realy appreciate it.

Hello Erwin,

I have a free example using a Microsoft Access 2003-2007 database that can be downloaded on my website which populated a listbox and textfields.

Xojo ODBC 2003-2007 Example

This was made for Windows since the path to the file is to be placed in a file folder located at: c:\test\. When the program runs, mouse click any filled row in the listbox and press the ‘Edit Record’ button and the textfields are populated from the listbox, and the listbox is populated from the database. This example is all performed in code.

Let me know if this works for you :slight_smile:

You simply have to populate the TextFields with the data you retrieve from the selected row in the ListBox.

The Eddie’s Electronics sample apps included with Xojo show you one technique for doing this:

Examples/Sample Applications/EddiesElectronics

Hi Erwin,

That is quite easy to achieve… drop me a line if you want some Dutch advice…


In a multimedia project of mine, I populate the ListBox with a master folder contents and store its FolderItem in the RowTag property.

When the user select a Row from the ListBox, I take that FolderItem from teh RowTab and load / display the text data (AND | OR image) into the TextArea.