ESRI.ArcGIS.E2API Feedback via the User Forum
FeatureCursor Class
See Also  Members   Example 
ESRI.ArcGIS.E2API Namespace : FeatureCursor Class


Represents a subset of features. A FeatureCursor can be used to enumerate through features in turn.

Syntax

Visual Basic (Declaration) 
<ComVisibleAttribute(False)>
Public NotInheritable Class FeatureCursor 
Visual Basic (Usage)Copy Code
Dim instance As FeatureCursor
C# 
[ComVisibleAttribute(false)]
public sealed class FeatureCursor 

Example

An example of enumerating the features in a LocalVectorLayer with a FeatureCursor. This example assumes there is a variable MyLocalVectorLayer pointing to a LocalVectorLayer (e.g. Shapefile).
C#Copy Code
ESRI.ArcGIS.E2API.FeatureCursor MyFeatureCursor = MyLocalVectorLayer.SearchFeatures(null, 
                                                   string.Empty, esriE2SpatialRelationship.Undefined); 
 
ESRI.ArcGIS.E2API.Feature MyFeature = MyFeatureCursor.NextFeature(); 
 
do 

  System.Diagnostics.Debug.WriteLine(MyFeature.GetValueAsString(0)); 
  MyFeature = MyFeatureCursor.NextFeature (); 
} while (MyFeature != null);
Visual BasicCopy Code
ESRI.ArcGIS.E2API.FeatureCursor MyFeatureCursor = MyLocalVectorLayer.SearchFeatures(Nothing,
                                                   String.Empty, esriE2SpatialRelationship.Undefined)

Dim MyFeature As ESRI.ArcGIS.E2API.Feature = MyFeatureCursor.NextFeature()

Do
  System.Diagnostics.Debug.WriteLine(MyFeature.GetValueAsString(0))
  MyFeature = MyFeatureCursor.NextFeature ()
Loop While Not MyFeature Is Nothing

Inheritance Hierarchy

System.Object
   ESRI.ArcGIS.E2API.FeatureCursor

Platforms

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

Version Information

This class was added to the E2API at version 1.0.0.348.

See Also