This document is archived and information here might be outdated. Recommended version. |
ArcObjects Help for .NET developers > ArcObjects namespaces > Geodatabase > ESRI.ArcGIS.GeoDatabase > Interfaces > IR > IRepresentationClass Interface > IRepresentationClass.GetRepresentation Method (ArcObjects .NET 10.5 SDK) |
Returns the representation of a given feature.
[Visual Basic .NET] Public Function GetRepresentation ( _ ByVal Feature As IFeature, _ ByVal MapContext As IMapContext _ ) As IRepresentation
[C#] public IRepresentation GetRepresentation ( IFeature Feature, IMapContext MapContext );
[C++]
HRESULT GetRepresentation(
IFeature* Feature,
IMapContext* MapContext,
IRepresentation** rep
);
[C++]
Parameters Feature [in]
Feature is a parameter of type IFeature MapContext [in]
MapContext is a parameter of type IMapContext rep [out, retval]
rep is a parameter of type IRepresentation
Use GetRepresentation method to get a reference to the feature representation for any feature with respect to its map context. Same features will have different representations when the map contexts change.
The following code snippet demonstrates the use of PrepareFilter and GetRepresentation methods. Reference to a RepresentationClass must be present to use this code: