Hi Guys need help with the Arcade expression. I got the expression working to get all the zones within a given parcel. I added a comma to for multiple zones within a parcel. However a comma also shows up at the end. How can I fix this expression so there is no comma at the end.
var intersectLayer =Intersects(FeatureSetByName($map,"Zones"),Buffer($feature, -10, 'feet'))
var zones = ""
for (var f in intersectLayer){
zones = Concatenate(zones, f.BASEZONE, ", ")
}
return zones
Solved! Go to Solution.
Hi aa.malik ,
One way of doing this is to create a list with all the values and at the end apply the concatenate to that list:
var intersectLayer = Intersects(FeatureSetByName($map,"Zones"),Buffer($feature, -10, 'feet'));
var zones = "";
var lst = [];
for (var f in intersectLayer){
lst[Count(lst)] = f.BASEZONE;
}
zones = Concatenate(lst, ", ");
return zones;
Hi aa.malik ,
One way of doing this is to create a list with all the values and at the end apply the concatenate to that list:
var intersectLayer = Intersects(FeatureSetByName($map,"Zones"),Buffer($feature, -10, 'feet'));
var zones = "";
var lst = [];
for (var f in intersectLayer){
lst[Count(lst)] = f.BASEZONE;
}
zones = Concatenate(lst, ", ");
return zones;
This is really great. Thank you!!