Macro code help - paste function not working

March 25, 2011 at 01:22:25
Specs: Windows XP
I am trying to use a macro to "database" information entered onto a form when a button/control is pressed. I have gotten every line of code to work except for the paste function line and cannot figure out why. It will work if I use Select on the field and then paste, but I am trying to keep the database page hidden. Any help would be appreciated.

Sheets("Database").Rows("2:2").Insert Shift:=xlDown, CopyOrigin:=xlFormatFromLeftOrAbove
Sheets("Mix Production").Range("A9:F9").Copy
Sheets("Mix Production").Range("A9:F9").ClearContents

See More: Macro code help - paste function not working

Report •

March 25, 2011 at 03:24:12
Try this format:

ActiveSheet.Paste Destination:=Worksheets("Sheet2").Range("a1")

Report •

March 25, 2011 at 03:32:21
Worked perfectly in that format. Thank you very much for the assistance!

Onto the next project now.

Report •

Related Solutions

Ask Question