J
jutlaux
I am using cascading combo boxes and have a SELECT statement in one of them
that I now want to add and ORDER BY statement to. When I added the ORDER BY
part to the working SELECT statement it did not ORDER the data. The cascading
part still worked, just no order to the second combo box. What did I do
wrong or miss?
Some other notes cboEquipmentID is the first combo box that populates the
second combo box cboCurrentMachineNum
Private Sub cboEquipmentID_AfterUpdate()
cboCurrentMachineNum.RowSourceType = "Table/Query"
cboCurrentMachineNum.RowSource = _
"SELECT intMachineNumber from tblMachineNumber WHERE strMachineType
= """ & cboEquipmentID & """ ORDER BY strMachineType"
End Sub
that I now want to add and ORDER BY statement to. When I added the ORDER BY
part to the working SELECT statement it did not ORDER the data. The cascading
part still worked, just no order to the second combo box. What did I do
wrong or miss?
Some other notes cboEquipmentID is the first combo box that populates the
second combo box cboCurrentMachineNum
Private Sub cboEquipmentID_AfterUpdate()
cboCurrentMachineNum.RowSourceType = "Table/Query"
cboCurrentMachineNum.RowSource = _
"SELECT intMachineNumber from tblMachineNumber WHERE strMachineType
= """ & cboEquipmentID & """ ORDER BY strMachineType"
End Sub