Hi Ben,
I like to render a google map (or google areal) as background of a shape Layer.
The projection of the shapeLayer (my projection example is Germany DHDN3, epsg 31467) should also be applied to the google map.
Can you please send me an example (Visual Basic) for that. I also want to use Postgres layer as overlay. Is this possible?
Thank you very much
With best regards J
Jörg
Ps. Unfortunaly the following source code (containing some german highway) which I get from the examples works not correct. It produces an south shift of the shapes against the google data of about 10 km.
If Not Page.IsPostBack Then Map1.MapBackground.BackgroundBrush = New GeoSolidBrush(GeoColor.FromHtml("#B3C6D4")) Map1.MapUnit = GeographyUnit.Meter Map1.MapTools.OverlaySwitcher.Enabled = True Map1.MapTools.MouseCoordinate.Enabled = True Dim google As New GoogleOverlay("Google Map") google.JavaScriptLibraryUri = New Uri(ConfigurationManager.AppSettings("GoogleUri")) google.GoogleMapType = GoogleMapType.Normal Dim shapeFileFeatureLayer As New ShapeFileFeatureLayer(MapPath("~/SampleData/Joerg/autobahn2.shp")) shapeFileFeatureLayer.ZoomLevelSet.ZoomLevel01.DefaultLineStyle = LineStyles.CreateSimpleLineStyle(GeoColor.StandardColors.Red, 2, True) shapeFileFeatureLayer.ZoomLevelSet.ZoomLevel01.ApplyUntilZoomLevel = ApplyUntilZoomLevel.Level20 Dim proj4 As New Proj4Projection() proj4.InternalProjectionParametersString = Proj4Projection.GetEpsgParametersString(31467) proj4.ExternalProjectionParametersString = Proj4Projection.GetGoogleMapParametersString() shapeFileFeatureLayer.FeatureSource.Projection = proj4 Dim shapeOverlay As New LayerOverlay("Shape Overlay", False, TileType.SingleTile) shapeOverlay.Layers.Add(shapeFileFeatureLayer) shapeOverlay.TransitionEffect = TransitionEffect.None shapeFileFeatureLayer.Open() Map1.CurrentExtent = shapeFileFeatureLayer.FeatureSource.GetBoundingBox() shapeFileFeatureLayer.Close() Map1.CustomOverlays.Add(google) Map1.CustomOverlays.Add(shapeOverlay) End If