Accessing feature layer properties from feature

659
1
09-21-2012 01:10 PM
VijayaprabhaRajendran
New Contributor
Hi All,

I have a collection of selected features from different feature layers.I want to loop through the selected features and get the name of feature layer for each selected feature using c#. Is it possible to fetch the name of feature layer from a selected feature?


Thanks,
Vijayaprabha.
0 Kudos
1 Reply
by Anonymous User
Not applicable
If its an edit selection then you can do it through IEnumMapFeature

IEnumFeature enumFeature = m_editor.EditSelection;
IEnumMapFeature enumMapFeature = enumFeature as IEnumMapFeature;
enumFeature.Reset();
enumMapFeature.Next(out m_origFeature, out m_selLayer);


You may have to revert to brute force for a general ArcMap selection.
0 Kudos