Sunday, February 2, 2014

How to merge cells in VBA (Excel)

Merging cells with VBA is one of the most easy commands in VBA.

You just need to specify the cells you want to merge, and give the instruction:

Sub Merge()

Worksheets(1).Range("A1:D1").Merge

End Sub

No comments: