Routing on OSF with GeoServer, offline

Topics: General
Sep 6, 2012 at 6:30 AM

Hallo, I use GeoServer a data from shp file by OpenStreetMaps. I can't to have connect to Internet. How Can I create routes between two points? Now I use this code in WPF:

List<PointLatLng> points = new List<PointLatLng>();           
points.Add(new PointLatLng(49.222979, 17.659786));           
points.Add(new PointLatLng(49.223736, 17.66878));           
points.Add(new PointLatLng(49.225649, 17.668707));

MapRoute r = GMapProviders.OpenStreetMap.GetRouteBetweenPoints(points[0], points[2], false, false, 15);                          

GMapMarker route = new GMapMarker(points[0]);           
route.Route.AddRange(r.Points);          
route.RegenerateRouteShape(this);           
route.ZIndex = -1;           
this.Markers.Add(route);

This line is problem:
MapRoute r = GMapProviders.OpenStreetMap.GetRouteBetweenPoints(points[0], points[2], false, false, 15); It's only ok, when I connect to Internet.

Can you help me? Thanks. Lada

Coordinator
Sep 6, 2012 at 7:44 AM

routing services are on servers, you can't use them offline unless you have cached results

Sep 6, 2012 at 8:09 AM
Edited Sep 6, 2012 at 8:52 AM

I haven't got cached results. GeoServer is server with geo data and runs on local computer. I connect to it as WMS provider. I think, I need somethink as GMapProviders.GeoServer.GetRouteBetweenPoints(.....?