ArcGIS Pro 2.9 API Reference Guide
FlashFeature(IReadOnlyDictionary<BasicFeatureLayer,List<Int64>>,Boolean) Method
Example 

ArcGIS.Desktop.Mapping Namespace > MapView Class > FlashFeature Method : FlashFeature(IReadOnlyDictionary<BasicFeatureLayer,List<Int64>>,Boolean) Method
The collection of layers and corresponding Object IDs to flash.
Will flash a crosshair.
Flash one or more features in the view simultaneously.
Syntax

Parameters

features
The collection of layers and corresponding Object IDs to flash.
showCrosshair
Will flash a crosshair.
Example
Flash the map's selcted features.
public Task FlashSelectedFeaturesAsync()
{
  return QueuedTask.Run(() =>
  {
    //Get the active map view.
    var mapView = MapView.Active;
    if (mapView == null)
      return;

    //Get the selected features from the map and filter out the standalone table selection.
    var selectedFeatures = mapView.Map.GetSelection()
      .Where(kvp => kvp.Key is BasicFeatureLayer)
      .ToDictionary(kvp => (BasicFeatureLayer)kvp.Key, kvp => kvp.Value);

    //Flash the collection of features.
    mapView.FlashFeature(selectedFeatures);
  });

}
Requirements

Target Platforms: Windows 11, Windows 10, Windows 8.1

See Also

Reference

MapView Class
MapView Members
Overload List