Is there a way to display labels in the same label class but different features as stacked? I have two polylines with identical geometry but have different values. Is there a way to display their labels as a stack instead of side by side?
Allowing the line labels to be placed above or below the line could help with situations where there are only 2 overlapping features. Set the Constrain offset parameter to No constraint to allow this.
The result can look like this:
Keep in mind other labels and weighted features on the map will influence label positions so the labels aren't guaranteed to align nicely like this.
So I found a way to do this using old school VBScript! I'm sure there's a way to do this with Arcade but I've been struggling with that. The syntax to copy/paste into the Expression box of the Label Class pane is:
Dim countercounter = 0
Function FindLabel ([Label])If Left([Label], 3) = "BFO" Thencounter = counter + 1If counter Mod 2 = 1 ThenFindLabel = "<SUP>" & [Label] & "</SUP>"ElseFindLabel = "<SUB>" & [Label] & "</SUB>"End IfElseFindLabel = [Label] ' If it doesn't start with "BFO", return the original labelEnd IfEnd FunctionThe result can be seen below. One thing I had to change to make it work properly was on the Position tab in the Label Class pane, set the Label Buffer to 0%. Then it stacks properly.
I was able to post it to ArcGIS Online and share it.
https://vps.maps.arcgis.com/sharing/rest/content/items/b0f156276d2a4dd1ad49b9e58a5686f7/data
So I have two polylines in the same feature class with identical geometry. Both labels are part of the same label class. They both have different names (BFO 48RI & BFO 288RI). The labels are displayed side by side and I would like them stacked one on top of the other. When I try to use stacking separators I end up with the BFO above the numbers but they are still side by side.
Hey @MasonFord
You may be able to just paste it in here, or possibly upload to imgur or another image exchange if that works!
Cody
I read through this post before creating this one. I tried using the stacking separators and it did stack each label individually but the two labels were still side by side. If I could upload a picture it would be easier to explain but I don't see an option for that.
I'm curious if stacking separators should do this for you?
Here is a post that shows someone following a challenge to recreate symbology, but it shows similar to what you're asking I believe:
https://community.esri.com/t5/arcgis-pro-questions/a-complicated-labeling-challenge-multiple-values/m-p/1474242#M83417
Angemeldete Mitglieder können Beiträge verfassen, Updates folgen und mehr. Neu hier? Registriere ein kostenloses Konto.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.