M
Mary A Perez
The form I'm working on for the user has a "Contract Name" combo box where
the user can choose a Contract Name, and I also have a "Contract Rate Sheet
Name" combo box where the user after choosing the Contract Name chooses the
Contract Rate Sheet Name associated only with that Contract Name.
The code is as such:
Private Sub cmbContractName_AfterUpdate()
Dim strSQL As String
If Nz(Me.cmbContractName, 0) <> 0 Then
strSQL = " Select ContractRateSheetNameId ,ContractRateSheetName "
strSQL = strSQL & " from tblContractRateSheetNames "
strSQL = strSQL & " where ContractId= " & Me.cmbContractName
With Me.cmbContractRateSheetName
.RowSource = strSQL
.Requery
End With
End If
End Sub
My question is that the user want the "Contract Rate Sheet Name" to be in
Alphabetical Order. How can I do this? I tried going to the
tblContractRateSheetNames" & sorting the ContractRateSheetName column in
ascending order, that didn't work, then I tried going to the row source query
& placing the sort order ascending in the ContractRateSheetName field, but
neither works.
Any suggestions?
the user can choose a Contract Name, and I also have a "Contract Rate Sheet
Name" combo box where the user after choosing the Contract Name chooses the
Contract Rate Sheet Name associated only with that Contract Name.
The code is as such:
Private Sub cmbContractName_AfterUpdate()
Dim strSQL As String
If Nz(Me.cmbContractName, 0) <> 0 Then
strSQL = " Select ContractRateSheetNameId ,ContractRateSheetName "
strSQL = strSQL & " from tblContractRateSheetNames "
strSQL = strSQL & " where ContractId= " & Me.cmbContractName
With Me.cmbContractRateSheetName
.RowSource = strSQL
.Requery
End With
End If
End Sub
My question is that the user want the "Contract Rate Sheet Name" to be in
Alphabetical Order. How can I do this? I tried going to the
tblContractRateSheetNames" & sorting the ContractRateSheetName column in
ascending order, that didn't work, then I tried going to the row source query
& placing the sort order ascending in the ContractRateSheetName field, but
neither works.
Any suggestions?