Hi All
I am trying to create an arcade expression that returns a URL to populate a survey123 form with a single path from numerous polylines with a common attribute, ordered by a segment id field. so basically I have multiple polylines to be converted into one long polyline and to be passed it into the survey123 form.
var mainTable= OrderBy(FeatureSetByPortalItem(Portal('https://tlilimerick.maps.arcgis.com/'),'xyz', 0),'Segment')
var Job = $feature.Job
var SQL1 = "Job='" + Job+"'"
var Polylines_in_Job = OrderBy(filter(Fibre,SQL1),'Segment')
var i = 0
for (var f in Fibre_Job) {
geom[i++] = Geometry(f);
}
return geom
the code above returns an array with the exact number of polyline objects required in it and normally I have no problem passing a single polyline in on it s own I just can t figure out how to access every vertex in each polyline and generating a new string to include in the URL. I got it to work for start and end points but that's not exactly what I want. I also realised i needed the order to be correct or else it would be a nonsensical line ,so I added a segment id to be prepopulated by the user to inform the desired route. 1,2,3 etc @XanderBakker would you be able to assist with this one?