Refill Combobox for each row

P

phil

I have a datasheet which contains a combobox. The combobox is filled with
values via a function. Is there any way I get can get the list to refill for
each row in the datasheet? The function only seems to refill the list each
time the form is opened even if I put the code in the On Current event. I'm
trying ot achieve a list of values that are dependant upon a key value within
the same row. E.G.

row 1, key value, <list of values based on row 1 key>
row 2, key value, <list of values based on row 2 key>
row 3, key value, <list of values based on row 3 key>
 
A

Al Campagna

Phil,
Not sure I understand... but...
Sounds like your combobox is either not bound to a field in your table,
or you're not requerying the combo box on each record's OnCurrent event.
And, I'm assuming you have a field on the form that the combo uses as a
filter for the records it delivers.

Try... (use your own control names)
Private Sub Form_Current()
Me.cboYourComboName.Requery
End Sub
--
hth
Al Campagna
Microsoft Access MVP
http://home.comcast.net/~cccsolutions/index.html

"Find a job that you love... and you'll never work a day in your life."
 

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