Hi ranman256
I changed the code to the On Exit of the Control "Labor" on the Subform
Code:
Private Sub Labor_Exit(Cancel As Integer)
10 On Error GoTo Labor_Exit_Error
Dim strSQL As String
' update parent record with current Total
20 CurrentDb.Execute "UPDATE tblContractPurchaseOrder SET OriginalContractSum = " & Me.Total _
& " WHERE CustomerPurchaseOrderID = " & Me!CustomerPurchaseOrderID & ";", dbFailOnError
' refresh parent form
30 [Forms]![frmContractAIADetails]![OriginalContractSum].Recalc
40 On Error GoTo 0
50 Exit Sub
Labor_Exit_Error:
60 MsgBox "Error " & Err.Number & " (" & Err.Description & ") in procedure Labor_Exit, line " & Erl & "."
End Sub
I now get the following error and when I click OK the correct value is displayed in the Control "OriginalContractSum"