Using the Infragistics xamGeographicMap control, trying to add shapes from SQL server geometry data.
So this works:
var majorCitySeries = new GeographicSymbolSeries { ItemsSource = data.cities, LatitudeMemberPath = "SP_GEOMETRY.YCoordinate", LongitudeMemberPath = "SP_GEOMETRY.XCoordinate" }; GeoMap.Series.Add(majorCitySeries);
But these show nothing:
var countySeries = new GeographicShapeSeries { ItemsSource = data.counties, ShapeMemberPath = "SP_GEOMETRY" }; GeoMap.Series.Add(countySeries); var br = new GeographicPolylineSeries { ItemsSource = data.rivers, ShapeMemberPath = "SP_GEOMETRY" }; GeoMap.Series.Add(br);
Do I need to add a converter? The samples, they tell nothing. What gives?
Hello Sjoerd,
Thank you for your feedback. I am glad that you resolved your issue and I believe that other community members may benefit from this as well. Also I can say that you can add this product idea here:
http://ideas.infragistics.com/
Ok, fixed it by manually building the converter out of my DbSet. Would you please consider adding native support for DbSet + DbGeometry?
I am just checking the progress of this issue and was wondering if you managed to achieve your goal or if you need any further assistance on the matter.
Thank you for your post. I have been looking into it and I can suggest you see the samples (“Binding Shape Files” and “Binding Database File”) in the Samples Browser under xamGeographicMap / Data section, where it is shown how to use ShapefileConverter, which should be used as ItemsSource of the Series. Please let me know if this helps you or you have further questions on this matter.
Looking forward for your reply.