This document is archived and information here might be outdated.  Recommended version.


Get The Selected Schematic Features In A ISchematicLayer Snippet (ArcObjects .NET 10.4 SDK)
ArcObjects Library Reference

Get The Selected Schematic Features In A ISchematicLayer Snippet

Retrieve all the schematic features currently selected in a ISchematicLayer

[C#]
        /// <summary>
        /// Retrieve all the schematic features currently selected in a ISchematicLayer
        /// </summary>
        /// <param name="schemLayer">The ISchematicLayer where the schematic features are selected</param>
        /// <param name="OnlyVisible">If OnlyVisible is true, only the visible selected features are returned</param>
        /// <returns>The retrieved IEnumSchematicFeature</returns>
        public ESRI.ArcGIS.Schematic.IEnumSchematicFeature GetSelectedFeatureFromSchematicLayer(ESRI.ArcGIS.Schematic.ISchematicLayer schemLayer, bool OnlyVisible)
        {
                return schemLayer.GetSchematicSelectedFeatures(OnlyVisible);
        }
[Visual Basic .NET]
        ''' <summary>
        ''' Retrieve all the schematic features currently selected in a ISchematicLayer
        ''' </summary>
        ''' <param name="schemLayer">The ISchematicLayer where the schematic features are selected</param>
        ''' <param name="OnlyVisible">If OnlyVisible is true, only the visible selected features are returned</param>
        ''' <returns>The retrieved IEnumSchematicFeature</returns>
        Public Function GetSelectedFeaturesFromSchematicLayer(ByVal schemLayer As ESRI.ArcGIS.Schematic.ISchematicLayer, ByVal OnlyVisible As Boolean) As ESRI.ArcGIS.Schematic.IEnumSchematicFeature

                Return schemLayer.GetSchematicSelectedFeatures(OnlyVisible)
        End Function

Additional Requirements
  • The code in this document requires the following References added to the Visual Studio project:
  • ESRI.ArcGIS.Schematic