Book Image

Windows Phone 7.5: Building Location-aware Applications

Book Image

Windows Phone 7.5: Building Location-aware Applications

Overview of this book

Windows Phone 7.5 has met with some great initial reviews from all mobile critics. It is poised to be the '3rd' eco-system for mobile, joining Apple's iOS and Google's Android platform. With Microsoft and Nokia working on multiple devices based on Windows Phone, the platform is a no-brainer enterprise success. Microsoft Office, Email, Skype and a fresh new mobile operating system has been a great champion of a cause for both Microsoft and Nokia. "Windows Phone 7.5: Building Location-aware Applications" will teach you to divein to the new Windows Phone Experience. No more 600 page bibles - just the right mix of text and lots of code to get you started!"Windows Phone 7.5: Building Location-aware Applications" covers location based services and maps, and focuses on methods of location detection and maps. Powered with this information, two real-world applications are covered. In short, this is a concise book on building location aware apps for Windows Phone.
Table of Contents (11 chapters)
Windows Phone 7.5: Building Location-aware Applications
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface

Working with Bing Maps geocoding and reverse geocoding services


The Bing Maps REST Services API provides API end points for forward geocoding (or just simple geocoding) as well as reverse geocoding. Static Maps API, Routing and Traffic APIs are supported as well. Refer to the following MSDN documentation for a complete look at the APIs:

http://msdn.microsoft.com/en-us/library/ff701722.aspx

In our previous example, we showed an alert when a user clicked or touched on a pushpin. The content of the alert was geocodes, however to make the app more informational and useful, we could use the reverse geocoding API from Bing Maps, and convert the geocodes to meaningful addresses. Here's how:

  1. 1. We use the Find a Location by Point API endpoint from the Bing Maps REST Service at:

    http://msdn.microsoft.com/en-us/library/ff701710.aspx

  2. 2. Import the following XML namespaces in your project so that we can parse the API response:

    using System.Xml;
    using System.Xml.Linq;
    
  3. 3. In your global class namespace...