ArcGIS Pro 3.8 API Reference Guide
ArcGIS.Desktop.Mapping.Events Namespace / MapControlEventHandler.Event<TEventArgs> Class / Subscribe Method
The delegate that gets executed when the event is published.
When false the event maintains a weak delegate reference to the subscriber.

In This Topic
    Subscribe Method (MapControlEventHandler.Event<TEventArgs>)
    In This Topic
    Subscribes to the event.
    Syntax

    Parameters

    action
    The delegate that gets executed when the event is published.
    keepSubscriberAlive
    When false the event maintains a weak delegate reference to the subscriber.

    Return Value

    A ArcGIS.Core.Events.SubscriptionToken that uniquely identifies the added subscription.
    Remarks
    Subscribers are invoked synchronously in subscription order until a subscriber sets MapControlEventArgs.Handled to true.
    Requirements

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

    ArcGIS Pro version: 3.8 or higher.
    See Also