The exact error returned are e.g. this: Find distance error:Error code '403':'User doesnot have permissions to access 'world/route.mapserver'.' I get the errortext, but this has worked before. My code is here: double totalMiles = 0;//double.MaxValue; try { MapPoint fromPoint = new MapPoint(fromLon, fromLat, SpatialReferences.Wgs84); MapPoint toPoint = new MapPoint(selected.lon, selected.lat, SpatialReferences.Wgs84); var fromSym = new SimpleMarkerSymbol { Style = SimpleMarkerStyle.X, Size = 50, Color = Colors.Green }; var toSym = new SimpleMarkerSymbol { Style = SimpleMarkerStyle.X, Size = 50, Color = Colors.GreenYellow }; var fromMapGraphic = new Graphic { Geometry = fromPoint, Symbol = fromSym };getLayer("graphicsLayer").Graphics.Add(fromMapGraphic); var toMapGraphic = new Graphic { Geometry = toPoint, Symbol = toSym }; getLayer("graphicsLayer").Graphics.Add(toMapGraphic); //var uri = new Uri("https://webadaptor.domain.com/arcgis/rest/services/folder/servicename/NAServer/Route"); var uri = new Uri("http://route.arcgis.com/arcgis/rest/services/World/Route/NAServer/Route_World"); var routeTask = new OnlineRouteTask(uri); var routeParams = await routeTask.GetDefaultParametersAsync(); //MessageBox.Show(routeParams.ToString()); routeParams.OutSpatialReference = ihmMapView.SpatialReference; routeParams.DirectionsLengthUnit = LinearUnits.Kilometers; routeParams.DirectionsLanguage = new System.Globalization.CultureInfo("EN"); routeParams.ReturnDirections = true; routeParams.OutputLines = Esri.ArcGISRuntime.Tasks.NetworkAnalyst.OutputLine.Default; routeParams.FindBestSequence = true; var stopGraphics = new List<Graphic>(); //stopGraphics.Add(fromMapGraphic); //stopGraphics.Add(toMapGraphic); routeParams.SetStops(stopGraphics); var routeResult = await routeTask.SolveAsync(routeParams); I (and the Danish firetrucks) would really apreciate some help here.
... View more