Good to hear that the solution works but I am sorry Sergey .. I do not have an idea on your second question. I think you can mark this post as Answered, so that i also get a point added 😛 .. and start a new post for your second question. 🙂 Regards, Pavan Well, thank you for your help, you helped me a lot!
... View more
It worked for me though.. I applied SelectlayerByAttributes on my layer. This is how did IFeatureLayer pFeatureLayer = GetFeatureLayer(); // I got my desired featurelayer from layers list displayed on map. SelectLayerByAttribute pSelect = new SelectLayerByAttribute(); pSelect .in_layer_or_view = pFeatureLayer; // directly take your featurelayerP or featurelayerC pSelect .selection_type = "NEW_SELECTION"; pSelect .where_clause = "id = '916EEBA8-7721-4BD3-8833-B61AC78A8F74'"; // I had given a Where condition .. "Country = India" pSelect.out_layer_or_view = "Filtered_layer"; copyfeatures.RunTool(GP, SelectByAttribute, null); // RunTool () as mentioned in the link // Intialize the CopyFeatures tool CopyFeatures CopyFeatures = new CopyFeatures(); // Here since the features are already selected in pFeatureLayer.. CopyFeatures.in_features = pFeatureLayer; // only selected elements are passed as in_features. CopyFeatures.out_feature_class = @"C:\Users\kharitonov.sv\Documents\ArcGIS\Default.gdb\Wells_Lyr_c"; // specify a valid path that exists copyfeatures.RunTool(GP, CopyFeatures, null); Worked for me this way.. i feel you should also get it. Regards, Pavan Yes it works, thanks a lot :))super,only had one more question, how to add a new layer in new map string outs = @"Database Connections\Connection to 192.168.56.102 (3).sde"; CopyFeatures.in_features = featlayerP; CopyFeatures.out_feature_class = outs+@"\\Wells_Lyr_c"; In this case, the data is added to the root directory. I need to add data to a certain data frame. Or how some way I need the creation of a new layer attribute structure of the other layer. [ATTACH=CONFIG]27109[/ATTACH]
... View more