L
Laura
I am trying to copy and paste a record in a table using a
command button. When I do this, it creates a table
called "Paste Error". I think it is because the table has
a primary key that is auto numbered. Here is the VB
behind the button:
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 2, , acMenuVer70
DoCmd.GoToRecord , , acNewRec
DoCmd.DoMenuItem acFormBar, acEditMenu, 5, ,
acMenuVer70 'Paste Append
DoCmd.GoToRecord , , acLast
line two copies, line three creates a new record, line
three pastes and line four goes to the last record made,
theoretically. But it doesn't work.
Thanks for any help!
command button. When I do this, it creates a table
called "Paste Error". I think it is because the table has
a primary key that is auto numbered. Here is the VB
behind the button:
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 2, , acMenuVer70
DoCmd.GoToRecord , , acNewRec
DoCmd.DoMenuItem acFormBar, acEditMenu, 5, ,
acMenuVer70 'Paste Append
DoCmd.GoToRecord , , acLast
line two copies, line three creates a new record, line
three pastes and line four goes to the last record made,
theoretically. But it doesn't work.
Thanks for any help!