IdentifyLayersAsync question

436
4
08-24-2022 09:13 AM
robymun
New Contributor II

Hi i'm in this situation, 

for example if I launch the identification near the red points I get the results correctly from the red dot layer

robymun_1-1661356905197.png

but if I do a small zoom out and i launch the identification in the same point and at that zoom level the layer is not visible I don't get results from the layer ... is that correct?

robymun_2-1661357523541.png

in this case i have zero results from dot red layer

 

Regards Roberto

 

 

 

 

 

0 Kudos
4 Replies
MichaelBranscomb
Esri Frequent Contributor

Hi,

That's the expected behavior: Identify will return visible GeoElements only.

For more info see:

Method IdentifyLayerAsync (arcgis.com)

Method IdentifyLayersAsync (arcgis.com)

 

Thanks

0 Kudos
robymun
New Contributor II

hi thank you for the answer

I ask this because in the old version 10.5.2 (now we are porting to 100) this did not happen and the client asks us to identify even if the layer at a certain zoom level is not visible. It is possible to get around the problem in some way

 

Regards Roberto

 

0 Kudos
ZackAllen
Esri Contributor

For a workaround, I suggest creating a buffer using the geometry of the tapped point. Then query the features using the buffer geometry as a query parameter. You could even scale the size of the buffer using the current  scale of the map view.

0 Kudos
robymun
New Contributor II

Thanks for the reply

We have about 100 layers on the map, which are active but visible at different zoom levels.

So there are no other alternatives to make a query for each single layer?

Regards Roberto

0 Kudos