ArcGIS Pro 3.7 API Reference Guide
ArcGIS.Desktop.Core Namespace / FrameworkExtender Class / OpenTablePane Method / OpenTablePane(PaneCollection,MapMember,TableViewMode) Method
The project's collection of panes returned from ArcGIS.Desktop.Framework.FrameworkApplication.Panes.
The mapMember for which the table pane will be opened.
The view mode of the table; show all records or selected records.
Example

In This Topic
    OpenTablePane(PaneCollection,MapMember,TableViewMode) Method
    In This Topic
    Opens a table pane for a MapMember. If a table pane is already open it will be activated. You must be on the UI thread to call this function.
    Syntax
    Public Overloads Shared Function OpenTablePane( _
       ByVal paneCollection As PaneCollection, _
       ByVal mapMember As MapMember, _
       Optional ByVal viewMode As TableViewMode _
    ) As ITablePane

    Parameters

    paneCollection
    The project's collection of panes returned from ArcGIS.Desktop.Framework.FrameworkApplication.Panes.
    mapMember
    The mapMember for which the table pane will be opened.
    viewMode
    The view mode of the table; show all records or selected records.

    Return Value

    Exceptions
    ExceptionDescription
    Table panes cannot be accessed from a thread other than the thread they were created on.
    The map viewer is not initialized.
    Remarks
    There must be an active map view otherwise a System.InvalidOperationException is thrown.
    Example
    Retrieve a table from its container
    {
        var container = MapView.Active.Map;
    
        //the map standalone table collection
        var table = container.GetStandaloneTablesAsFlattenedList()
                                .FirstOrDefault(tbl => tbl.Name == "EarthquakeDamage");
    
        //or from a group layer
        var grp_layer = MapView.Active.Map.FindLayers("GroupLayer1").First() as GroupLayer;
        var table2 = grp_layer.FindStandaloneTables("EarthquakeDamage").First();
        //or         grp_layer.GetStandaloneTablesAsFlattenedList().First()
        //or         grp_layer.StandaloneTables.Where(...).First(), etc.
    
        //show the table in a table view 
        //use FrameworkApplication.Current.Dispatcher.BeginInvoke if not on the UI thread
        FrameworkApplication.Panes.OpenTablePane(table2);
    }
    Requirements

    Target Platforms: Windows 11 Home, Pro, Enterprise (64 bit)

    ArcGIS Pro version: 3.0 or higher.
    See Also