AnsweredAssumed Answered

identifyLayersWithMaxResults crashes app

Question asked by on Oct 25, 2018
Latest reply on Oct 26, 2018 by

I have a map with multiple feature layers.

I'm trying to identify a layer that is clicked on but I do not know which one will be clicked


So I have this line of code which as I understand it should accomplish what I want to do


mapView.identifyLayersWithMaxResults(mouse.x, mouse.y, 22, false, 1);


which should trigger in here

    onIdentifyLayerStatusChanged: {


but instead what happens this line of code mapView.identifyLayersWithMaxResults(mouse.x, mouse.y, 22, false, 1);
crashes my app everytime

I was trying to follow the instructions per
Identify features—ArcGIS Runtime SDK for Qt | ArcGIS for Developers 

Identify features in all feature layers

When you do not know which specific layer to identify on, you can identify items in any layer in the map or scene. Change the first workflow above so that you do not specify the layer to identify. This time, the results are returned as a list of IdentifyLayerResult instead of a single result.

Layers that do not support identify or do not have any results based on the inputs are not included in the returned list.