K
Kurt Häusler
Hi.
I have a subform (this is a very standard order form, with item list
subform) with 2 combo boxes on it.
The first combo box chooses which section I want. For example, Doors,
Roofing, Outdoor, Windows, Indoor, Electrical. This combo box sets the
Row Source for the second combo box.
I do this with this VB code:
Private Sub Combo10_Change()
Me.Combo12.RowSource = "SELECT [Extras].[Extra-Id],
[Extras].[Description] FROM Extras WHERE
[Extras].[Section]=Combo10.Value; "
End Sub
Now combo12 is bound, but when the above code runs, it changes the Row
Source of that combo box for every record! This means that we cant
look back up at already entered records and see the description,
except where the section is the same as the current section.
So, my question is, if Me. refers to the whole form i.e. All records,
how do I refer to specifically the control ONLY on the current record?
Thanks a lot.
Kurt
I have a subform (this is a very standard order form, with item list
subform) with 2 combo boxes on it.
The first combo box chooses which section I want. For example, Doors,
Roofing, Outdoor, Windows, Indoor, Electrical. This combo box sets the
Row Source for the second combo box.
I do this with this VB code:
Private Sub Combo10_Change()
Me.Combo12.RowSource = "SELECT [Extras].[Extra-Id],
[Extras].[Description] FROM Extras WHERE
[Extras].[Section]=Combo10.Value; "
End Sub
Now combo12 is bound, but when the above code runs, it changes the Row
Source of that combo box for every record! This means that we cant
look back up at already entered records and see the description,
except where the section is the same as the current section.
So, my question is, if Me. refers to the whole form i.e. All records,
how do I refer to specifically the control ONLY on the current record?
Thanks a lot.
Kurt