0
votes

I'm trying to write a macro to copy and paste some cells. I want to select all of the cells directly below a merged cell.

So for example, if cell C5 was merged to E5, then I would want to select cells C6 to E6. However the width of the merged cell will differ, so I can't simply use Range("C6:E6").Select.

I don't want to include the merged cell in the selection, so I can't just use Range("C5:C6").

Any help would be much appreciated.

1

1 Answers

1
votes

First select the merged cell group and then:

Sub dural()
    With Selection
        .UnMerge
        .Offset(1, 0).Select
        .Merge
    End With
End Sub