Requery problem

  • Thread starter Thread starter tonydepo
  • Start date Start date
T

tonydepo

Ok. I going to try to explain this, so please bear with me. I have
subform in a main form. In this subform it is displayed as a datashee
view. If a person picks a plazaID for example PLAZA1, then the nex
field which is the LANES field should only display the lanes availabl
for that plaza. I want the plazaID field to have a change property.
Meaning, if someone picks a new plaza for that one record, the lane
field will then get focus and only show the lanes available for tha
plaza. The thing is this form is based on products. So their ar
multiple lane equipment in one product. I tried a requery, but it wil
do every lane that already has something assign to it in the subform.
want to be able to only requery the one record the user selects in th
subform.

Thank
 
tonydepo,

There are two ways that I know of to handle this problem...
1. This will not work on a datasheet. You will have to change your
subform to Continuous view. Place a textbox over the top of the data
part of the combobox, but with the drop-down arrow of the combobox still
visible. Apply to the textbox from the Format|BringToFront menu. Set
the controlsource of the textbox so it shows the Lane data from the
combobox. Then, when you click the combobox's arrow button, the
combobox gets the focus and works as usual, but after that the data is
shown in the textbox.
2. Make a query that only returns the records associated with the
selected Plaza in the first combobox, which I think is what you already
have. Make another query which returns the Lanes already selected in
previous records. Make a Union Query which joins these two together,
and use this union query as the Row Source of the Lanes combobox.

Sorry, both of these solutions require a bit of work to set up.
 
Back
Top