C
Confused Slug
I am using the biult in wizard to create a button on a form and to duplicate
the record and paste the info into a new record / form, re below. However,
the form contains a subForm and i would like this information to be
duplicated at the same time as the main form and pasted into the new record.
How would i code this?
Private Sub DuplicateRecordButton_Click()
On Error GoTo Err_DuplicateRecordButton_Click
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 2, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 5, , acMenuVer70 'Paste Append
Exit_DuplicateRecordButton_Click:
Exit Sub
Err_DuplicateRecordButton_Click:
MsgBox Err.Description
Resume Exit_DuplicateRecordButton_Click
End Sub
Thanks
Confused
the record and paste the info into a new record / form, re below. However,
the form contains a subForm and i would like this information to be
duplicated at the same time as the main form and pasted into the new record.
How would i code this?
Private Sub DuplicateRecordButton_Click()
On Error GoTo Err_DuplicateRecordButton_Click
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 2, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 5, , acMenuVer70 'Paste Append
Exit_DuplicateRecordButton_Click:
Exit Sub
Err_DuplicateRecordButton_Click:
MsgBox Err.Description
Resume Exit_DuplicateRecordButton_Click
End Sub
Thanks
Confused