Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

Apologies if this is easy but I cannot seem to find the answer. Is there a way to convert a graphic to feature, i.e. use the "Convert Graphics to Feature" tool on the toolbar, within arcpy?

I need to use a graphic as a selectbylayer feature, so either converting it or using the graphic directly would be nice.

share|improve this question

1 Answer 1

There appears to be no SelectLayerByGraphic tool equivalent to SelectLayerByLocation so I think you are correct to seek an alternative approach.

There also appears to be no "ConvertGraphicToFeature" tool.

I looked for whether you could access a graphic drawn in Data View from Python but GRAPHIC_ELEMENTs appear to be available for resizing and repositioning only.

If what you are looking for is a way to feed a "graphic" drawn by the end user into a Python script tool then the alternative you may wish to use is to request the user to draw the "graphic" by using a Feature Set as a parameter.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.