Articles in this section
Category / Section

How to visualize Bing Maps in the .NET MAUI Maps (SfMaps)?

2 mins read

In the Syncfusion® .NET MAUI Maps control, you can visualize Bing Maps.

To add the Bing Maps, you must set the UrlTemplate property of the MapTileLayer in the SfMaps.

For Bing Maps, a subscription key is needed to request tiles. You can create your own Bing Maps key by following the steps mentioned in this link and replace “YOUR_KEY” in the following code sample with the actual key before passing it to the top-level GetBingUrl method, which returns the URL in the required format.

Set the URL returned to the UrlTemplate property of the MapTileLayer.

C#:

public MainPage()
{
   InitializeComponent();

   SfMaps map = new SfMaps();
   MapTileLayer tileLayer = new MapTileLayer();
   this.GenerateBing(tileLayer);
   map.Layer = tileLayer;
   this.Content = map;
}

private async Task GenerateBing(MapTileLayer tileLayer)
{
   tileLayer.UrlTemplate = await MapTileLayer.GetBingUrl("https://dev.virtualearth.net/REST/V1/Imagery/Metadata/RoadOnDemand?output=json&uriScheme=https&include=ImageryProviders&key=YOUR_KEY") + "?name=bingName";
} 

Output:

BingMap in Syncfusion® .NET MAUI Maps

Conclusion:
I hope you enjoyed learning how to visualize Bing Maps in .NET MAUI Maps (SfMaps).
You can refer to our .NET MAUI Maps feature tour page to learn about its other groundbreaking feature representations. Explore our .NET MAUI Maps documentation to understand how to present and manipulate data.
For current customers, check out our .NET MAUI components from the License and Downloads page. If you are new to Syncfusion®, try our 30-day free trial to check out our .NET MAUI Maps and other .NET MAUI components.
Please let us know in the comments section if you have any queries or require clarification. You can also contact us through our support forums, Direct-Trac, or feedback portal. We are always happy to assist you!

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please  to leave a comment
Access denied
Access denied