AnsweredAssumed Answered

create new layer from selected features

Question asked by sailitang on Apr 18, 2012
Latest reply on Apr 19, 2012 by kenbuja
Hi,

    Now I am working on an add-ins. I am using VB.NET and ArcInfo 10. I am using following code to do selection for a layer:

Dim featureselection As IFeatureSelection = TryCast(pMap.Layer(i), IFeatureSelection)

Dim queryFilter As IQueryFilter = New QueryFilter

queryFilter.WhereClause = "Key = 'LK'"

featureselection.SelectFeatures(queryFilter, esriSelectionResultEnum.esriSelectionResultNew, False)

On the next step, I would like to export the selected features to a geodatabase, and then load it to the map as a layer.

Anyone knows how to write the code to export the selected features to a geodatabase? Thanks.


Saili

Outcomes