Copy & Paste (Merged & Centered)

C

Cathy

In Sheet1, I have Cells A1:D1 "Merged & Centered" with bold letters for
the title of the page

I am trying to write a macro top copy and Paste the Text from A1:C1 to
Sheet2!D2 (after inserting a new column in D2)

The problem is that after pasting in D2, the contents of E2 and F2 are
also cleared as it seems because the copied area is merged over three
cells, the pasted area is pasted over three cells.

Is there a way I could make this only Paste in Cell D2

For reference, this is what I am using:
Sheets("Sheet1").Select
Range("A1").Select
Selection.Copy
Sheets("Sheet2").Select
Range("D2").Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone,
SkipBlanks:= _
False, Transpose:=False

Thanks in advance

Cathy
 
D

Dave Peterson

Maybe just assigning the value would work better:

Worksheets("sheet2").Range("D2").Value _
= Worksheets("sheet1").Range("a1").Value
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top