This documentation is archived and is not being maintained.

ListObject.Parent Property


Gets the parent object of the ListObject control.

Namespace:   Microsoft.Office.Tools.Excel
Assembly:  Microsoft.Office.Tools.Excel (in Microsoft.Office.Tools.Excel.dll)

object Parent { get; }

Property Value

Type: System.Object

The parent object of the ListObject control.

The following code example creates a ListObject and then displays the name of its parent object in a message.

This example is for a document-level customization.

private void ListObject_Parent()
    Microsoft.Office.Tools.Excel.ListObject list1 =
        this.Range["A1", "C4"], "list1");

    Excel.Worksheet list1Parent = (Excel.Worksheet)list1.Parent;
    MessageBox.Show("The parent of list1 is " +
Return to top