Reputation: 23
I have a Main Form named "GSAPAccounts" referred to a query with the same name and another form (not a subform) named "Failures" referred to query also named as failures.
I have a condition in my GSAPAccounts where, when a condition is met, Failures (form) will pop out. In my Failure forms I have 2 fields to be populated "General Reason" and "Comments" (which is also in my GSAPAccounts Form) and a command button to close the form, and I also have included the "ID" as the common field between the 2 forms.
My question now is: Is it possible that when I make changes in my "Failures" form to reflect it in my "GSAP Accounts" form?
I am quite new to MS Access, and what I've done so far is just the code below. When I make changes in the Failures form, it is not updating in my other form. I already tried everything that I can find in Google but nothing is working for me.
If IsNull(Me.General_Reason) Or IsNull(Me.Comments) Then
MsgBox "Provide M15 Failure Reason"
Else
DoCmd.Save
DoCmd.Close
End If
Upvotes: 0
Views: 81
Reputation: 55831
You could refresh or requery the other form in the AfterUpdate event of form "GSAP Accounts":
Forms!Failures.Refresh
'or:
' Forms!Failures.Requery
Upvotes: 1