Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms Programming / May 2008

Tip: Looking for answers? Try searching our database.

Refill Combobox for each row

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
phil - 13 May 2008 11:38 GMT
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>
Al Campagna - 13 May 2008 14:16 GMT
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
Signature

   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."

>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
[quoted text clipped - 9 lines]
> row 2, key value, <list of values based on row 2 key>
> row 3, key value, <list of values based on row 3 key>
phil - 13 May 2008 17:55 GMT
Huh!, didn't think I'd need the requery - thanks.

> Phil,
>     Not sure I understand... but...
[quoted text clipped - 20 lines]
> > row 2, key value, <list of values based on row 2 key>
> > row 3, key value, <list of values based on row 3 key>
Al Campagna - 13 May 2008 22:46 GMT
Phil,
   You would if the combo is unbound.
Signature

   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."

> Huh!, didn't think I'd need the requery - thanks.
>
[quoted text clipped - 27 lines]
>> > row 2, key value, <list of values based on row 2 key>
>> > row 3, key value, <list of values based on row 3 key>

Rate this thread:






 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.