D
Dan Knight
I've got a continous formwith an AutoNumber as the Primary key field.
At present I can select multiple records and using the Edit Menu, Copy
command, I can copy these records and then use the Edit Menu, Paste Append
command to append the multiple records to the table.
I want to be able to automate that two step process using a command button
on the Header of the form. I've used the command button wizard and it works
fine, BUT it only select a single record; So with the button, I select my
multiple records, then press the button and it only paste the first record of
the muliple selection.
I've looked at the resultant code from the wizard and see that it references
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
I attempted unsucessfully to reference
DoCmd.DoMenuItem acmenuBar, acEditMenu, acCopy
and even to use
DoCmd.RunCommand acCmdDuplicate
I can't get these to work. They return an error message that says:
"the command or action 'Duplicate' (or Copy) isn't available now"
What I'm wondering is:
1) Can the functionality that is present natively using the menubar and Edit
menu, not be replicated in VBA?
2) If it can, how?
Thanks in advance,
Dan Knight
I'd like to be able to have a button that enables
At present I can select multiple records and using the Edit Menu, Copy
command, I can copy these records and then use the Edit Menu, Paste Append
command to append the multiple records to the table.
I want to be able to automate that two step process using a command button
on the Header of the form. I've used the command button wizard and it works
fine, BUT it only select a single record; So with the button, I select my
multiple records, then press the button and it only paste the first record of
the muliple selection.
I've looked at the resultant code from the wizard and see that it references
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
I attempted unsucessfully to reference
DoCmd.DoMenuItem acmenuBar, acEditMenu, acCopy
and even to use
DoCmd.RunCommand acCmdDuplicate
I can't get these to work. They return an error message that says:
"the command or action 'Duplicate' (or Copy) isn't available now"
What I'm wondering is:
1) Can the functionality that is present natively using the menubar and Edit
menu, not be replicated in VBA?
2) If it can, how?
Thanks in advance,
Dan Knight
I'd like to be able to have a button that enables