Query Task and Spatial Query

551
1
09-06-2010 07:02 AM
MarcoRosa
New Contributor
hi to all,

I've a function who make spatial query between a selected poligons on a featurelayer and other features. The selected polygon are on featurelayer f.
Now when i've 1 selected feature the geometry passed on query task is correctly

query.Geometry = f.Graphics[0].Geometry;

If i have 2 or more poligon selected on feature f ?

Thank you very much in advanced as usuall
GD
0 Kudos
1 Reply
JenniferNery
Esri Regular Contributor
The feature layer has SelectedGraphics property. Instead of passing the graphic's geometry directly to your Spatial query, you can create an Envelope based on the SelectedGraphics' geometries. You can then use this Envelope for your query.
0 Kudos