Solved

Using the ListBox control with a database field

Posted on 1998-08-26
2
163 Views
Last Modified: 2010-04-30
I just started learning VB and I am just getting use to the controls.  My question is how do I get the contents of a field to appear in the listbox.  I am using a FoxPro table.

Thanks.
0
Comment
Question by:MLHAMMEL
2 Comments
 
LVL 4

Accepted Solution

by:
mcix earned 50 total points
ID: 1431114
To use a bound list box there are two steps...

1. Insert a data control on the form and set the connect properties, database name and recordsource properties.

2. Insert a reference to the databound ListBox, this is different than the standard list box in the ToolBox, you will need to go to <P>roject menu and select Componen<t>s.... It should appear in the list.

3. On the DBList control, set the rowsource property to the data control you created and then set ListField and BoundColumn properties.

Hope this gets you started...
0
 

Author Comment

by:MLHAMMEL
ID: 1431115
Very good.  Thanks a lot.
0

Featured Post

Is Your AD Toolbox Looking More Like a Toybox?

Managing Active Directory can get complicated.  Often, the native tools for managing AD are just not up to the task.  The largest Active Directory installations in the world have relied on one tool to manage their day-to-day administration tasks: Hyena. Start your trial today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question