ListObject.InsertRowRange Property

Excel Developer Reference

Returns a Range object representing the Insert row, if any, of a specified ListObject object. Read-only Range.



expression   A variable that represents a ListObject object.


If the Insert row is not visible because the list is inactive, the Nothing object will be returned.


The following example activates the range specified by the InsertRowRange in the default ListObject object in the first worksheet of the active workbook.

Visual Basic for Applications
  Function ActivateInsertRow() As Boolean
    Dim wrksht As Worksheet
    Dim objList As ListObject
    Dim objListRng As Range
    Set wrksht = ActiveWorkbook.Worksheets(1)
    Set objList = wrksht.ListObjects(1)
    Set objListRng = objList.InsertRowRange
If objListRng Is Nothing Then
    ActivateInsertRow = False
    ActivateInsertRow = True
End If

End Function

See Also