F
Frederick Wilson
Hello,
I have a form that has a combo box and a list box. The list box is based
off of the selection for the combo box
cboBox Rowsourse=
SELECT distinct TngType FROM tblEvents UNION select "[ALL]" from
tblevents ORDER BY tblEvents.TngType;
the listbox Rowsourse=
SELECT tblEvents.EventCode, tblEvents.Event, tblEvents.TngType FROM
tblEvents WHERE (((tblEvents.TngType) Like
IIf(Forms!frmInputCTT!cboEventType="[ALL]","*",Forms!frmInputCTT!cboEventType)))
ORDER BY tblEvents.Event;
The overall function works fine BUT...
When I set the default value of the cbo to =
[cboEventType].[itemdata](0) the query for the list box fails when the
form opens.
If I remove the reference to the cbo from the list box row source, the
list box shows everything and the cbo shows the first item. However now
the afterupdate event in the cbo fails to requery the list box.
How do I get this to work?
I have a form that has a combo box and a list box. The list box is based
off of the selection for the combo box
cboBox Rowsourse=
SELECT distinct TngType FROM tblEvents UNION select "[ALL]" from
tblevents ORDER BY tblEvents.TngType;
the listbox Rowsourse=
SELECT tblEvents.EventCode, tblEvents.Event, tblEvents.TngType FROM
tblEvents WHERE (((tblEvents.TngType) Like
IIf(Forms!frmInputCTT!cboEventType="[ALL]","*",Forms!frmInputCTT!cboEventType)))
ORDER BY tblEvents.Event;
The overall function works fine BUT...
When I set the default value of the cbo to =
[cboEventType].[itemdata](0) the query for the list box fails when the
form opens.
If I remove the reference to the cbo from the list box row source, the
list box shows everything and the cbo shows the first item. However now
the afterupdate event in the cbo fails to requery the list box.
How do I get this to work?