Hide labels for markers in a cluster (AKA FeatureReduction) when clustered

382
3
Jump to solution
10-20-2025 04:25 AM
Kaju
by
Emerging Contributor

I have some markers with labels attached to them and I am trying to hide their labels when they get clustered. 

When the cluster explodes (disables automatically because of zooming in) I need to see the labels like so:

Kaju_0-1760958566981.png

But when clustered, I want it to turn into:

Kaju_3-1760958696700.png

Rather than:

Kaju_2-1760958616108.png

My markers and clusters are stored in the MapView's GraphicsOverlays list.

 

Thanks in advance

0 Kudos
1 Solution

Accepted Solutions
Kaju
by
Emerging Contributor

Thanks for the response!

After some more digging around, I found that the issue was the following code executing every time the user zoomed in:

Kaju_0-1761123449557.png

That for each loop was causing the labels to enable themselves - I'm not sure what purpose it serves but that's been resolved.

Thanks for your help!

View solution in original post

3 Replies
TDraeseke
Esri Contributor

Hi Kaju!

Thanks for your post. This is definitely not expected behaviour.

Is there any chance you could share your data so we can try to reproduce it?

If the data isn't sensitive you can drag and drop the file just below these comments or you can email me directly at tdraeseke@esri.com

 

Thanks!

Trevor

TDraeseke
Esri Contributor

This should all be supported, but I maybe saw on another post that you've implemented your own clustering logic?

Here's some guides and samples to help using in house clustering with feature reduction, for which labeling is supported:

https://developers.arcgis.com/net/styles-and-data-visualization/display-clusters/

https://github.com/Esri/arcgis-maps-sdk-dotnet-samples/tree/main/src/MAUI/Maui.Samples/Samples/Layer...

 

Thanks!

0 Kudos
Kaju
by
Emerging Contributor

Thanks for the response!

After some more digging around, I found that the issue was the following code executing every time the user zoomed in:

Kaju_0-1761123449557.png

That for each loop was causing the labels to enable themselves - I'm not sure what purpose it serves but that's been resolved.

Thanks for your help!