I have a form with two sections. The top of the form uses a combobox to get the Contract Number. I have an On_Click that I am using to display the Contractor and Name of MATO (Contract Name) but it will only pick up one field.
Code:
SELECT tblContractLevelMATO.[Contract Number], tblContractLevelMATO.[Name of MATO], tblContractLevelMATO.Contractor FROM tblContractLevelMATO ORDER BY tblContractLevelMATO.[Contract Number] DESC;
Private Sub Contract_Number_Click()
Me.MATO_Name = Me.Contract_Number.Column(2)
Me.Contractor = Me.Contract_Number.Column(3)
End Sub
Is there a better way to get corresponding data into these text boxes besides using an On_click procedure?
I have another part of the form where I will be using this logic as well. Once I select a Task Order I need to display 9 fields from the table that match that Task Order Number in various textboxes on the form.