Forum Discussion
GeoJSON reference layer - location labels/names
Thanks for the reply! Ok, several questions...
For the fictious locations, I want 2 points (Lat / Lon / name changed etc) and I have this as GeoJSON and TopoJSON (seems to be little difference? and isn't a polygon, points are fine / basic)
{
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"properties": {
"color": "Red",
"name": "LBR1"
},
"geometry": {
"coordinates": [
-0.087724,
51.507904
],
"type": "Point"
},
"id": 0
},
{
"type": "Feature",
"properties": {
"color": "Red",
"name": "LBR2"
},
"geometry": {
"coordinates": [
-0.087724,
51.507904
],
"type": "Point"
},
"id": 1
}
]
}
As far as I understand it, I can drop this in as a reference layer and this works showing 2 red dots, but how would I get the name to show (all the time / on hover) or something? Unless I'm missing the point of reference layers... I'd basically like a layer where nothing changes (Home layer) and then dynamic data I can slice 'n' dice. Thoughts welcomed! Cheers Keith
Have a "name" field in your data model that carries the values in your "name" property. Declare that field as a geo place.
- Anonymous3 years agoNot applicable
Hi
Thanks for getting back to me.
Ok, so the very simple model is :
And I drop postcode onto an Azure map to show postcodes. Works a treat. I then have the GeoJSON file mentioned earlier. Unsure where the 'name' field should be going? Do I create a a tabel with 2 values in LBR1 / LBR2 and the column is called name? Apologies if I sound dumb... And thanks for your help!
Cheers
- lbendlin3 years agoSuper User
Do I create a a tabel with 2 values in LBR1 / LBR2 and the column is called name?If that makes sense in your data model, yes. One of your dimension fields in the data model will need to tie to the name attribute in the JSON.
- jusTodd2 years agoAdvocate IV
I am a little confused. I have the field "Location" designated as a Place, but how exactly do I tie that back?