Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Create GeoJson c#

I'm trying to create a simple example for creating GeoJson file.

I read the tool GeoJson.NET, but I do not quite understand how to create this file.

I'll be glad if someone could give me a small example of creating GeoJson with a number of Points, and explain me how I can use it without creating a file, but to transfer the Json to JavaScript file because I want to make a call to the database every user entry system for give the data in real time.

like image 578
Shalom Dahan Avatar asked Feb 03 '26 11:02

Shalom Dahan


1 Answers

I found the solution to my problem

First Read my answer from the following link: Make points for Google Maps using GeoJSON.Net in C#

After creating GeoJson should return it to JavaScript and then have to use the following line:

map.data.addGeoJson(JSON.parse(result));
like image 116
Shalom Dahan Avatar answered Feb 05 '26 23:02

Shalom Dahan



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!