How to: Get a Bing Maps Key
- 2 minutes to read
Map applications require a Bing Maps key to use the Bing Maps' image (BingMapDataProvider) and GIS (BingSearchDataProvider, BingGeocodeDataProvider, BingRouteDataProvider, and BingElevationDataProvider) data providers . A map image layer displays the following message if no key is assigned to the BingMapDataProvider.BingKey property.
Information layers that use Bing Maps GIS services to provide data do not show such messages. You can handle the LayerBase.Error event to access to the Bing Maps server's error responses (for example, "The remote server returned an error: (401) Unauthorized.").
The message suggests you visit the https://www.microsoft.com/en-us/maps/create-a-bing-maps-key page. This page contains information about the available key types. This guide explains how to create a Basic Key.
Expand the Basic Key section using its drop-down arrow.
- Study information about how you can use a Basic Key.
- Click the GET THE BASIC BING MAPS KEY > button to go to the Bing Maps Portal.
On this page, click the Sign In button. You should have a Microsoft account to continue.
Refer to the Creating a Bing Maps Account document in MSDN for detailed steps on how to create a Bing Maps account.
- After you login in to the Bing Maps portal, you are ready to create a Bing Maps key.
Select the My Keys item from the My Account drop-down list.
In the My keys section, click the corresponding link to create a new key.
In the Create key form, fill key parameters and click the Create button.
See the Getting a Bing Maps Key document in MSDN for more information on how to create a Bing Maps key.
After you get your Bing Maps key, assign it to the provider's BingKey property.