Bing Map connector

How To Get Your Location Name Using Bing Map Connector?

Have you ever thought about integrating a GPS component into your app? You can do this with Power App and in this article, we will show you how to create an application with Power Apps that uses Bing Maps to give your users a dynamic maps system that uses your GPS.

First of all, you have to connect Bing Map connector to your app.

Bing Map connector

It will ask you to enter your key, if you don’t have a key, you can generate a new one by signup at https://www.bingmapsportal.com/ also by filling in your app details as shown below

Bing Map connector

You have two options to generate a key:

  • Basic Key
  • Enterprise Key

Choose what works for you and generate it, then copy and paste it into the connector.

Now you need to get the location name based on your longitude and latitude, so you need to use the Location Table that was already created by Microsoft in the Dataverse.

Bing Map connector

As you see in the picture above, I used to declare a variable in a Button to store my location coordinates.

//Set(myLocation, BingMaps.GetLocationByPoint(Location.Latitude, Location.Longitude))//

*Note: you can put this code in another control to store your location coordinates.

BingMaps: connector.

GetLocationByPoint(): function with two parameters one for latitude and the other for longitude.

Location.Latitude: will get your location latitude.

Location.Longitude: will get your location longitude.

Bing Map connector

I used the TextInput control to view my location name, as you see in the picture above.

My variable name (MyLocation) dot name, it will return your location name.

So now it’s simple to obtain the location name without the user having to explicitly provide it and reflect new features that will be helpful to your user.