Combo Box Error in Form

G

Guest

Hi All!

I am creating a form that has two combo boxes. The first combo box is a
SUBJECT LIST and the second a SUBTOPIC LIST. The combo boxes work fine
independently as a subform; however, when placed in the form the Subtopic
combo box does not filter properly to show the subtopics associated with the
corresponding subject.

Why does it work independently and not when included in the form? I'm using
an AfterUpdate Event in the first cboSubjectSelect combo box that looks like:

!Mecbosubtopicselect.requery
!Mecbosubtopicselect.setfocus

However, when I convert to Form View I am asked to Enter Parameter Value for
Forms!frmCalllog_subform!cboSubjectSelect - as if it doesn't recognize the
field at all.

I would be greatful for any assistance on this error.
 
G

Guest

Hi Lesley,

See a reply from former Access MVP Sandra Daigle
http://groups.google.com/group/micr..._frm/thread/e033253ffea2b09f/718a00e1deccf74f

"…the problem you are seeing is due to the fact that there is really only
one combo control - it is just displayed multiple times. So whatever you have
for current rowsource will apply to all rows. This makes it difficult to use
synchronized combos on continuous forms. However, there is a fairly easy
workaround. To create the effect of a synchronized combo in a continuous form
create another textbox control, include the display column of the combo in
the Recordsource query of the form (join the foreign table and drag in the
column). Position and size the new textbox so that you can place it directly
over the combo box allowing only the down-arrow portion of the combo to show.

Create a GotFocus event for the textbox that only does a SetFocus to the
combo.

This will create the effect that you are wanting - the correct display value
will always show even though the value itself might not be fit the criteria
that is in effect based on the current record.

Here's a KB Article that explains the problem
(ACC2000:) Combo Box in Continuous Form Shows Incorrect Data
http://support.microsoft.com/?id=208866

Here's a link to my sample database that offers several different
alternatives for displaying this type of data including the technique
described above:

http://www.daiglenet.com/msaccess.htm"


Also, here is a tip from FMS on this topic:

Tip #16: Data in a combo box control on a continuous form/datasheet
disappears
http://www.fmsinc.com/free/tips.html#tip16foraccess


Tom Wickerath
Microsoft Access MVP

http://www.access.qbuilt.com/html/expert_contributors.html
http://www.access.qbuilt.com/html/search.html
__________________________________________
 

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

Similar Threads


Top