G
Guest
Hi,
Does anyone know how to test for records in a combobox and, if there are
none, set enabled to false. I would like the user to not fool with the
element if it doesn't apply to the part they have selected.
Here is the code I am using to filter the records in the combo boxes
(cascading).
Me.Text2.RowSource = "Select distinct parts.width " & _
"FROM parts " & _
"WHERE parts.ItemDesc = '" & descrip.Value & "' " & _
"ORDER BY parts.width;"
Me.Text4.RowSource = "Select distinct parts.length " & _
"FROM parts " & _
"WHERE parts.ItemDesc = '" & descrip.Value & "' " & _
"ORDER BY parts.length;"
Me.Text6.RowSource = "Select distinct parts.height " & _
"FROM parts " & _
"WHERE parts.ItemDesc = '" & descrip.Value & "' " & _
"ORDER BY parts.height;"
Thanks in advance.
Does anyone know how to test for records in a combobox and, if there are
none, set enabled to false. I would like the user to not fool with the
element if it doesn't apply to the part they have selected.
Here is the code I am using to filter the records in the combo boxes
(cascading).
Me.Text2.RowSource = "Select distinct parts.width " & _
"FROM parts " & _
"WHERE parts.ItemDesc = '" & descrip.Value & "' " & _
"ORDER BY parts.width;"
Me.Text4.RowSource = "Select distinct parts.length " & _
"FROM parts " & _
"WHERE parts.ItemDesc = '" & descrip.Value & "' " & _
"ORDER BY parts.length;"
Me.Text6.RowSource = "Select distinct parts.height " & _
"FROM parts " & _
"WHERE parts.ItemDesc = '" & descrip.Value & "' " & _
"ORDER BY parts.height;"
Thanks in advance.