ComboBox Row Source = Result of DB Query?

  • Thread starter Thread starter Zachary Turner
  • Start date Start date
Z

Zachary Turner

I have an access database and I want to populate a combo box with the
contents of a Table in my access database. What is the best way to do
it? I was trying to do it at design time, but not sure if it can be
done.
 
The easiest way would be to drag the table from server explorer (you
will need to create a new DB connection to the access table in the
server explorer to be able to view the table) onto your form, the
required connections and adapters get automatically setup, create a
dataset by r-clicking on the adapter, next set the datasource property
of the combo to the dataset.

These articles describe this in detail
http://www.developer.com/net/vb/article.php/3092741
http://www.startvbdotnet.com/ado/server.htm

Sijin Joseph
http://www.indiangeek.net
http://weblogs.asp.net/sjoseph
 
Back
Top