If you're using Bing Maps with ASP.NET MVC, then you'll want check out the
MvcMaps project. It's a unified api for implementing Bing Maps and Google Maps within an ASP.NET MVC Web Application.
For example you can place a default Bing Map within a View using the following code:
<script type='text/javascript'>
.BingMap { width: 600px; height: 400px; border: solid 1px black; }
</script>
<% Ajax.BingMap() // Create a Bing Map
.CssClass("BingMap") // Define the CSS Style to use. These specify the Maps Size
.Render(); // Render all the HTML / JavaScript necessary to create the Map to Server.Response
%>
You can also view a basic tutorial on getting started with MvcMaps here:
http://pietschsoft.com/post/2009/11/02/MvcMaps-Preview-1-e28093-A-Unified-BingGoogle-Maps-API-for-ASPNET-MVC.aspx The current release of MvcMaps at the time of this posting is "Preview 1". It's still pretty much an "Alpha" release, but I'm looking for others to provide feedback on the project. Please post comments at the above link or within the
MvcMaps Project Discussion Board .
Additionally, the MvcMaps project utilizes the Bing Maps JavaScript Control for rendering the map.
Microsoft MVP - Windows Live Platform
Blog:
http://pietschsoft.com |
Web.Maps.VE - ASP.NET AJAX Virtual Earth Server Control