Or in VBa
Sub intersectRowCol()
Set isect = Application.Intersect(Range("B:B"), Rows(2))
If Not isect Is Nothing Then
MsgBox isect
End If
Set isect = Nothing
End Sub
or in more general terms
Function intersectRowCol(RowNo As Long, ColumnRef As String)
Set isect = Application.Intersect(Range(ColumnRef), Rows(RowNo))
If Not isect Is Nothing Then
intersectRowCol = isect
End If
Set isect = Nothing
End Function
called as
myValue = intersectRowCol(2, "B:B")
Hope this helps.
If you need any further information, please feel free to ask further
However
If this takes care of your needs, please click EDIT in your original post, click GO ADVANCED and set the PREFIX box to SOLVED. It helps everybody!
Also
If you are satisfied by any members response to your problem please consider using the scales icon top right of thier post to show your appreciation.
Bookmarks