view: @{ Html.ThinkGeo().Map("Map1", new System.Web.UI.WebControls.Unit(100, System.Web.UI.WebControls.UnitType.Percentage), 510) .MapBackground(new BackgroundLayer(new GeoSolidBrush(GeoColor.StandardColors.White))) .CurrentExtent(142273.397380151, 454356.07030608, 473560.82562814, 169450.546640289) .MapUnit(GeographyUnit.Meter) .StaticOverlay(overlay => { WmsRasterLayer wmsLayer = new WmsRasterLayer(); wmsLayer.Uri = new Uri("http://openbasiskaart.nl/mapcache/"); wmsLayer.Parameters.Add("FORMAT", "image/gif"); wmsLayer.Parameters.Add("SRS", "EPSG:28992"); wmsLayer.ActiveLayerNames.Add("osm"); overlay.Layer("WmsLayer", wmsLayer); }) .Render(); } Controller: [MapActionFilter] public string ToPdf(Map map, GeoCollection args) { PdfDocument document = new PdfDocument(); PdfPage page = document.AddPage(); string selectedItemText = args[0].ToString(); if (selectedItemText == "Landscape") { page.Orientation = PageOrientation.Landscape; } PdfGeoCanvas pdfGeoCanvas = new PdfGeoCanvas(); // This allows you to control the area in which you want the // map to draw in. Leaving this commented out uses the whole page //pdfGeoCanvas.DrawingArea = new Rectangle(200, 50, 400, 400); Collection labelsInLayers = new Collection(); foreach (Layer layer in map.StaticOverlay.Layers) { RectangleShape printExtent = ExtentHelper.GetDrawingExtent(map.CurrentExtent, (float)map.WidthInPixels, (float)map.HeightInPixels); pdfGeoCanvas.BeginDrawing(page, printExtent, GeographyUnit.DecimalDegree); layer.Open(); layer.Draw(pdfGeoCanvas, labelsInLayers); layer.Close(); pdfGeoCanvas.EndDrawing(); } string relativePath = string.Format("~/Controllers/{0}/{1}", ControllerContext.RouteData.Values["Controller"], "MapSuite PDF Map.pdf"); string filename = Server.MapPath(relativePath); document.Save(filename); return VirtualPathUtility.ToAbsolute(relativePath); }