?
Solved

Using the ListBox control with a database field

Posted on 1998-08-26
2
Medium Priority
?
189 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 4

Accepted Solution

by:
mcix earned 200 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

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses
Course of the Month14 days, 2 hours left to enroll

801 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