Nanette said:
Having a bit of trouble. I had to change the RFQType (on the main form) to a
list box so that it sychronizes with the RFQNo combo box (on the main form).
The RFQNo combox is used to select the correct RFQNo, which another list box
is also based on. This other list box displays three FKs so the user can
select the items he wants. This will eventually fill in another subform that
displays certain data about each RFQNo. I tried to set the RFQType to a text
box to do this, but that didn't work.
I keep getting a message box that asks for the RFQType. Even after I choose
a RFQNo and a RFQType is displayed in the list box.
I'm getting confused again. Let's at least try to get our
nomenclature straight. A column in a table/query is called
a **field**. A thingie on a form/report is called a
**control**. Access often defaults to using the same name
for a control that is bound to field. This can lead to
confusion, sometimes even Access gets confused about using
the same name for two different objects. To avoid this
confusion, whenever you have code, an expression or a
property the refers to a field or its bound control, it is a
good idea to change the name of the control to something
else. It is a common practice to set the bound control's
name to the field name prefixed by three characters that
indicate the type of the control. For example, if your list
box is bound (ControlSource property) to the RFQType field
in the form's record source table/query, then set the list
box's name to lstRFQType.
With all that in mind, what are the names of the fields in
the main form and the subform record source? What are the
names of the main form controls that are bound to the fields
that are related to whatever it is that you now have? From
now on, please use the control and field names instead of
"other listbox", "a text box", "another subform" or any
other hand waving phrase.
The Link Master Fields property can refer to either controls
on the main form or to fields in the main form's record
source table/query.
The Link Child Fields property can only refer to fields in
the subform control's SourceObject form's record source
table/query.
The value placed in a combo or list box's bound field is
determined by their BoundColumn property,
When you are prompted for a value when you open a form or
report (or query), it means that whatever you are prompted
for is not in the form/report's RecordSource or combo/list
box's RowSource query's table. This implies that you added
the RFQType field to the wrong or inappropriate query.