Opening a ComboBox with a default selection in Access 2000

L

Louis

Please, how can we affect a default index in a cboBox at the opening of a form (thru VBA code or else...)
Let say I want the 3rd entree out of 10 to show at the opening of the form..
 
D

Dan Artuso

Hi,
Sure, something like this:
Me.cboCust = Me.cboCust.ItemData(2)

in the Open event.
 
M

Marshall Barton

Louis said:
Please, how can we affect a default index in a cboBox at the opening of a form (thru VBA code or else...).
Let say I want the 3rd entree out of 10 to show at the opening of the form..


Use the form's Load event:

Me.cboBox = Me.cboBox.ItemData(2)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top