cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ThenewThom
Frequent Visitor

Inserting GeoJSON into Power Apps map

Hi - the Microsoft documentation on this appears to indicate that you can import GeoJSON format to the map on an app in the following article:-  

Let users draw and insert shapes into maps - Power Apps | Microsoft Docs

"If you already have shapes defined in GeoJSON format, you can import them directly into your map."

 

Just wondering if there is any further detail which explains the procedure for how this is carried out. I've looked pretty thoroughly at the relevant posts and the only procedure I can infer is the creation of a SharePoint List from the GeoJSON file and then adding SharePoint as the connector. Which doesn't seem as direct as may be indicated in the article. Have I missed something here? Any guidance would be gratefully received. Cheers, T

3 REPLIES 3
Expiscornovus
Dual Super User
Dual Super User

Hi @ThenewThom,

 

You could create a list in SharePoint with a couple of columns. Make sure you use the multiple lines of text type for the GeoJSON coordinates field.

 

Below is an example of that approach.

 

1. Create a list in SharePoint.

I renamed Title to Country and created the GeoJSON & RGBColour fields.

 

geolocation_countries_spolist.png

 

2. Add the list to the Canvas App. In the Map control you should be able to select the list in the Shapes_Items.

After that you should be able to map the other fields as well (ShapeGeoJSONObjects, ShapeLabels & ShapeColors).

 

geolocation_countries.png

Hello and thank you for taking the time to respond. Just to confirm, when you have specified the ShapeGeoJSONObjects field have you simply referenced the 'column_name' alone or provided 'Shapefile.column_name'. Cheers

Expiscornovus
Dual Super User
Dual Super User

Hi @ThenewThom,

 

In my setup/test just providing the column_name (GeoJson) was sufficient.

Helpful resources

Announcements
PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Top Solution Authors
Top Kudoed Authors
Users online (1,519)