I know this seems like a random one! but I have a really long merged cell called "Model Length". it can vary as to where it is on the sheet. what I want to do is return two variables one containing the column number of the start of the merged cell, the other to return the column number of the end of the merged cell.
I currently have
Sub FindMerged4()
Dim c As Range
Dim sMsg As String
sMsg = ""
For Each c In ActiveSheet.UsedRange
If c.MergeCells Then
If sMsg = "" Then
sMsg = "Merged worksheet cells:" & vbCr
End If
sMsg = sMsg & c.Address & vbCr
End If
Next
If sMsg = "" Then
sMsg = "No merged worksheet cells."
End If
MsgBox sMsg
End Sub
Which returns a list of all the cells in the merged cell but I cant figure out how to identify the start and finish points.
Please help
thanks
Jim
Bookmarks