I had a form with a Sub Form. When I entered a product Serial number on the main form, the Subform would update to show any prior entries for that serial number. No programing was needed. It worked great.
Then I added a second Subform for Windows License information. I added a routine to the AfterUpdate event for my serial number field that would ask for Windows license information only for certain part numbers. If the part didn't use a Windows license the Subform was passed by. That worked great.
But I lost the update to the original history SubForm. It no longer will update the history like it used to.
I believe it is because of my AfterUpdate event code.
While searching the forum, I found this bit of code:
With Me![SubFrmHistory] 'put in my subForm name
.Form.Requery
End With
I added this code to my after event code. I put it after the End If and before the End Sub. But I get an error that says Access can not find the field.
Where do I need to put this code (or other code) so that my History Sub Form updates like it used to?
Then I added a second Subform for Windows License information. I added a routine to the AfterUpdate event for my serial number field that would ask for Windows license information only for certain part numbers. If the part didn't use a Windows license the Subform was passed by. That worked great.
But I lost the update to the original history SubForm. It no longer will update the history like it used to.
I believe it is because of my AfterUpdate event code.
While searching the forum, I found this bit of code:
With Me![SubFrmHistory] 'put in my subForm name
.Form.Requery
End With
I added this code to my after event code. I put it after the End If and before the End Sub. But I get an error that says Access can not find the field.
Where do I need to put this code (or other code) so that my History Sub Form updates like it used to?