Change event missing from Forms 2.0 combo box.

B

Billy Smith

I'm doing a project in Access 2000 using forms and MS Forms 2.0 combo
boxes. I'm not using the native Access combo box because it lacks an
Add Item method and is therefor very difficult to populate.

I want to do something when the user makes a selection in the combo box
so I need to respond to the Change event. The object browser shows a
number of events including Click and Change available for the combo box.
However, these events do not appear in property list of the combo box
so I cannot get to them.

I have confirmed that I'm using the Forms 2.0 combo box and not the native
one (both the object browser and the OLE class property of the combo box
say so).

Something else really strange is that a week or so ago in the same
project file I made a form with this same kind of combo box and the
Change event was available. The code is there and it works. Now,
even if I add another Forms 2.0 combo box to the form I made last week,
the change event is missing.

I've also confirmed that about 15 properties like Match Entry and Style
are set as they are in the combo box from last week's form just in case
the Change event is somehow available only for a certain combination
of properties. But that does not help.

Any ideas of why these events are missing or a workaround? It's beginning
to look like a bug to me. Thanks in advance.

--Billy
 
D

Douglas J. Steele

Just because the Events don't show up in the Properties dialog doesn't
usually matter (although I must admit that I don't use the Forms controls).
In the VB Editor, if you choose the combo box from the list at the top left
of the module, does the Change event show up in the list at the top right of
the module?
 
B

Billy Smith

Doug,

Yup, the Change event is in that list. And when I double click on it VB
generates the proper event handler stub code and that solves my problem.
I don't think I ever created an event handler that way but now I will.
Live and learn.

Thanks for your help.

--Billy
 

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