This is a helpdesk App that I'm working on. It is a VB6 front end with an access 2000 back end. I have a form that has several ADO controls on it along with several text boxes and combo boxes. One combo box drop down list is populated with technician names at form load by looping through a record set with the following code:
While cboAssignedTo.ListCount < datTechInfoRS.Recordset.RecordCount
cboAssignedTo.AddItem (datTechInfoRS.Recordset.Fields("Technician_Name")
datTechInfoRS.Recordset.MoveNext
Wend
The ADO control linked to table already populated with the info on the technicians(Name,Location,Email,ETC..). Based on the choice the user makes from the technician combo box, I would like to automagically populate another text box with that technicians email address from the same table. I not sure how to code it so that it looks at the cboAssignedTo.text value do a lookup for the record associated with that name and place the email address from the same record into the other text box. I hope I've giving enough info , thanks in advance.
While cboAssignedTo.ListCount < datTechInfoRS.Recordset.RecordCount
cboAssignedTo.AddItem (datTechInfoRS.Recordset.Fields("Technician_Name")
datTechInfoRS.Recordset.MoveNext
Wend
The ADO control linked to table already populated with the info on the technicians(Name,Location,Email,ETC..). Based on the choice the user makes from the technician combo box, I would like to automagically populate another text box with that technicians email address from the same table. I not sure how to code it so that it looks at the cboAssignedTo.text value do a lookup for the record associated with that name and place the email address from the same record into the other text box. I hope I've giving enough info , thanks in advance.