H
HumanJHawkins
Hi all,
I have tried several other things that were not directly an answer to
this from other posts, but have not had success. I have code that finds
the record I want to delete, but I can't figure out the delete part:
Me.AllowDeletions = True
Me.iTheKeyField.SetFocus
DoCmd.FindRecord Me.SearchForDeletion
' Make sure FindRecord didn't fail and leave us on a different
record
If (Me.iTheKeyField = Me.SearchForDeletion) Then
' Delete the current record!!!
Me.Requery
End If
Me.AllowDeletions = False
In case it matters, this is an .adp connected to a SQL data source.
Thanks in advance for any help!
I have tried several other things that were not directly an answer to
this from other posts, but have not had success. I have code that finds
the record I want to delete, but I can't figure out the delete part:
Me.AllowDeletions = True
Me.iTheKeyField.SetFocus
DoCmd.FindRecord Me.SearchForDeletion
' Make sure FindRecord didn't fail and leave us on a different
record
If (Me.iTheKeyField = Me.SearchForDeletion) Then
' Delete the current record!!!
Me.Requery
End If
Me.AllowDeletions = False
In case it matters, this is an .adp connected to a SQL data source.
Thanks in advance for any help!