Jim,
One way...
Sub tgr()
Dim rngFound As Range
Dim arrMerged(1 To 65000, 1 To 3) As Variant
Dim strFirst As String
Dim MergedIndex As Long
Dim i As Long
With Application.FindFormat
.Clear
.MergeCells = True
End With
Set rngFound = Cells.Find(vbNullString, Cells(Rows.Count, Columns.Count), xlValues, xlPart, SearchFormat:=True)
If Not rngFound Is Nothing Then
strFirst = rngFound.Address
Do
MergedIndex = MergedIndex + 1
arrMerged(MergedIndex, 1) = rngFound.MergeArea.Address
arrMerged(MergedIndex, 2) = rngFound.Column
arrMerged(MergedIndex, 3) = rngFound.Column + rngFound.MergeArea.Columns.Count - 1
Set rngFound = Cells.Find(vbNullString, rngFound, xlValues, xlPart, SearchFormat:=True)
Loop While rngFound.Address <> strFirst
For i = 1 To MergedIndex
MsgBox "Merged Cell Address:" & vbTab & arrMerged(i, 1) & Chr(10) & _
"Start Column Number:" & vbTab & arrMerged(i, 2) & Chr(10) & _
"End Column Number: " & vbTab & arrMerged(i, 3)
Next i
End If
Application.FindFormat.Clear
Set rngFound = Nothing
Erase arrMerged
End Sub
Bookmarks