C
Confused Slug
Re: Duplicate the information held in a form and the subform and pasteappend
into a new record.
I wish to duplicate the information held on one form and paste it into a new
form (record) I am using the code below to perform this action ok. 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.RunCommand acCmdSaveRecord
DoCmd.RunCommand acCmdSelectRecord
DoCmd.RunCommand acCmdCopy
DoCmd.RunCommand acCmdPasteApend
Exit_DuplicateRecordButton_Click:
Exit Sub
Err_DuplicateRecordButton_Click:
MsgBox Err.Description
Resume Exit_DuplicateRecordButton_Click
End Sub
Thanks
Confused
into a new record.
I wish to duplicate the information held on one form and paste it into a new
form (record) I am using the code below to perform this action ok. 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.RunCommand acCmdSaveRecord
DoCmd.RunCommand acCmdSelectRecord
DoCmd.RunCommand acCmdCopy
DoCmd.RunCommand acCmdPasteApend
Exit_DuplicateRecordButton_Click:
Exit Sub
Err_DuplicateRecordButton_Click:
MsgBox Err.Description
Resume Exit_DuplicateRecordButton_Click
End Sub
Thanks
Confused