ArcGIS Pro 3.2 API Reference Guide
ArcGIS.Core.Data Namespace / CoreDataExtensions Class / AddActivationExtension Method
The table with which the extension id will be registered
The extension id (guid) to be registered
Example

In This Topic
    AddActivationExtension Method
    In This Topic
    Registers an extension id (guid) with the specified table. This method must be called on the Main CIM Thread. Use QueuedTask.Run.
    Syntax
    public static void AddActivationExtension( 
       Table table,
       Guid extensionId
    )
    Public Shared Sub AddActivationExtension( _
       ByVal table As Table, _
       ByVal extensionId As Guid _
    ) 

    Parameters

    table
    The table with which the extension id will be registered
    extensionId
    The extension id (guid) to be registered
    Exceptions
    ExceptionDescription
    This method or property must be called within the lambda passed to QueuedTask.Run.
    Value cannot be null: table
    extension id cannot be empty
    Remarks
    Any number of extension ids can be added to a table. Adding an extension id will limit the backward compatibility of the given table/feature class to ArcGIS Pro 3.1...meaning the given table or feature class cannot be used or referenced within ArcGIS Pro 3.0 or earlier.
    As with all properties that change the minimum client version, removing all activation extension ids will recompute the minimum required client version. So removing activation extensions potentially allows older clients to open the table (depending on what other Geodatabase functionality is enabled on the table). Refer to RemoveActivationExtension
    Activation extension ids are supported on registered classes in Enterprise, File, Mobile and on ArcObjects Feature Service geodatabases.
    Calling AddActivationExtension when the table is being edited will fail.
    Registering an extension id (guid) with a table allows it to participate in special behaviors. One example of this is the ability to show a custom tab in the Pro Editor Attributes dockpane when rows from the table are selected. The following development process outlines how to achieve this special behavior:
    • In an add-in, implement a ArcGIS.Desktop.Editing.Attributes.AttributeTabEmbeddableControl. The associated daml entry for this class updates the “esri_editing_AttributeTabs” category. Assign a unique guid value (i.e. the "extension id") to the "guid" attribute value in the content element tag within the addin Config.daml.
    • In a separate administrative process, or within a separate addin, register the table(s) which are to show the custom tab with the same guid (i.e. "extension id") referenced in step 1 above - using the AddActivationExtension method.
    Note that eve though multiple extension ids can be registered to a single table or feature class and each of these extension ids has an AttributeTabEmbeddableControl component defined (in the config.daml), only one of the registered components will be added as a custom tab in the Attributes dockpane. That is; only ONE custom tab can be displayed in the Attributes dockpane for a feature class or table.
    Example
    Table Extension Ids
    public void ExtensionIds1(Table table)
    {
      //Add an extension id to a table
      //Check documentation for restrictions on backward compatibility - backward
      //compatibility is limited to ArcGIS Pro 3.1 if an extension id is added.
      //Note: This is an extension method. It is for use in addins only and not CoreHost.
      string extension_id_string = "52d8f3be-b73d-4140-beaf-23d4f9b697ea";
      Guid extension_id = Guid.Parse(extension_id_string);
    
      //Note: Must be within the lambda of QueuedTask.Run(() => { ...
    
      //register the extension id with the relevant table
      table.AddActivationExtension(extension_id);
    
      //Remove an extension id from a table
      //Restores backward compatibility assuming no other compatibility limitations are
      //in place.
      //Note: This is an extension method. It is for use in addins only and not CoreHost.
      table.RemoveActivationExtension(extension_id);
    
      //Check if a given extension id  is registered with a particular table.
      //Note: This is an extension method. It is for use in addins only and not CoreHost.
      if (table.GetHasActivationExtension(extension_id))
      {
        //TODO - implement custom logic relevant to presence of extension_id
      }
    
      //Enumerate all extension ids on a given table.
      //Note: This is an extension method. It is for use in addins only and not CoreHost.
      foreach (Guid ext_id in table.GetActivationExtensions())
      {
        //TODO - logic based on extension ids
      }
    }
    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3.1 or higher.
    See Also