Copy Record Issues With Unique Value

K

Karl Burrows

Hi!

Working on a small membership database for a interior design professionl
group. If I try to copy an existing record into a new record, I get an
error message telling me the unique value (membership number) can not be
duplicated. At that point, the only thing I can do is hit the escape key
and start a record from scratch. Is there a way to tell the copy macro
(built-in button command) to copy all except the primary , unique value
field?

Thanks!

Private Sub CopyRecord_Click()
On Error GoTo Err_CopyRecord_Click

DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 2, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 5, , acMenuVer70 'Paste Append

Exit_CopyRecord_Click:
Exit Sub

Err_CopyRecord_Click:
MsgBox Err.Description
Resume Exit_CopyRecord_Click

End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top