I use this code to identify and delete new duplicate records, when as it is captured.
I would like to Move the focus then to the row where a duplicate item was originally captured, in the subform (maybe a few lines up).
Please assist
I would like to Move the focus then to the row where a duplicate item was originally captured, in the subform (maybe a few lines up).
Code:
If DCount("[acquireid]", "tblAcquire", "acquireid<>" & acquireID & _
" AND Client_lookup=" & Client_lookup & _
" AND Item_Lookup=" & Item_Lookup & " AND Order_No=" & Order_no) > 0 Then
msg = "This is a duplicate ICN code for this Facility Order. Please do not add duplicate entries" & vbNewLine
msg = msg & "The record will now be undone"
MsgBox msg, vbExclamation, "System Duplication Message"
Me.Undo
Cancel = True
End If
Comment