Z
Zoltar54
I have a subform whcih allows me to select a number of services for each
order I receive (drilling, excavation, survey, screening etc..). Each option
listed in the combo box display the service, estimated time, and estimated
cost. Once a service is selected only the service type is displayed (such as
excavation) and I would like to have the other information (estimated time
and cost) displayed in an additional text box. I have been trying to do this
with VBA however I keep getting an error.
Below is the code which I am using, could someone please help me identify my
error?
Private Sub ServiceID_AfterUpdate()
Dim strfilter As String
On Error GoTo errorhandler
strfilter = "ServiceID=" & Me!ServiceID
Me.Description = DLookup("Descritpion", "tblService", strfilter)
Exit Sub
errorhandler:
MsgBox "Error#" & Err.Number & vbCrLf & Err.Description
order I receive (drilling, excavation, survey, screening etc..). Each option
listed in the combo box display the service, estimated time, and estimated
cost. Once a service is selected only the service type is displayed (such as
excavation) and I would like to have the other information (estimated time
and cost) displayed in an additional text box. I have been trying to do this
with VBA however I keep getting an error.
Below is the code which I am using, could someone please help me identify my
error?
Private Sub ServiceID_AfterUpdate()
Dim strfilter As String
On Error GoTo errorhandler
strfilter = "ServiceID=" & Me!ServiceID
Me.Description = DLookup("Descritpion", "tblService", strfilter)
Exit Sub
errorhandler:
MsgBox "Error#" & Err.Number & vbCrLf & Err.Description