Routing -> set custom names for stops

05-30-2017 06:28 AM
New Contributor II

Hi there!

Recently I've been working on cool routing functionality using the SDK and the ArcGIS world route service.

However, in the route directions, the string containing the direction gives me default names for stops (location 1, location 2 etc...).

I would like to set these manually and I know the route service allows it, since I've done it with the Qt Runtime SDK 100.

However, I can't find a way to do it with the Appstudio SDK. I have looked through the docs and found documentation on the input fields for stops, but now how to set them from the sdk. I've tried setting attributes for the graphics which I add as stops and setting the name of the graphic, as follows:

    function getStopGraphic( geometry, name ) {
        var stopGraphicClone = stopGraphic.clone();
        stopGraphicClone.geometry = geometry.project( routeSpatialReference ); = name;
        stopGraphicClone.setAttributeValue( "Name", name );
        layers.graphicsLayerRoute.addGraphic( stopGraphicClone );
        return stopGraphicClone;

Unfortunately, to no result whatsoever.

If anyone has the solution or more suggestions on what to try, I'd be very grateful.

Kind regards,


0 Kudos
3 Replies
Esri Contributor

Two samples that might be of interest:

arcgis-appstudio-samples/Online routing at master · Esri/arcgis-appstudio-samples · GitHub 

arcgis-appstudio-samples/Closest facility online at master · Esri/arcgis-appstudio-samples · GitHub 

You could also use the TextToSpeech module AppStudio provides to read out the stops/address to the end user if your platform supports it.

Since you see these in the new version of Runtime I would suggest you wait another month for the AppStudio 2.0 release and you will have Runtime 100.1 version included in that (and other very cool features).

0 Kudos
New Contributor II

Thank you for your reply.

Unfortunately the samples do not answer my question, since they rely on the default stop names (location 1, location 2).

It is however great to hear that the new version of AppStudio will support Runtime v100. Is there a place where I could read more about the upcoming updates?

0 Kudos
Esri Regular Contributor

Hi Pim,

AppStudio 2.0 was released and now supports the latest ArcGIS Runtime 100.1 for mapping capabilities.  Please update the AppStudio Desktop, Click on the New App button and search for "Find a Route" sample.  I hope this is helpful.



0 Kudos