Developer technologies | C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Hi Michel,
1.Can you please passed on these files and see if there are problems with them?
If yes can you please provide the fixes.
2.In this FromOption function in FileExtensionHelpers.cs.txt
I do not handle .json since of ambiguity
with these formats:
{ “.json”, “GeoJson” }, { “.json”, “EsriJson” }, { “.json”, “GeoJsonSeq” }, { “.json”, “TopoJson” },
How is cab be solved ?
public static FileExtension? FromOption(string option)
{
if (string.IsNullOrWhiteSpace(option)) return null;
switch (option.Trim().ToLowerInvariant())
{
case "csv": return FileExtension.Csv;
case "esrijson": return FileExtension.EsriJson;
case "gdb":
case "gdbtable":
case "gdbtablx":
return FileExtension.FileGdb;
case "geojson": return FileExtension.GeoJson;
case "jsonl":
case "ndjson":
return FileExtension.GeoJsonSeq;
case "gpkg": return FileExtension.GeoPackage;
case "gml": return FileExtension.Gml;
case "gpx": return FileExtension.Gpx;
case "kml": return FileExtension.Kml;
case "kmz": return FileExtension.Kmz;
case "mif":
case "mid": return FileExtension.MapInfoInterchange;
case "tab":
case "dat":
case "map":
case "id":
return FileExtension.MapInfoTab;
case "osm": return FileExtension.Osm;
case "shp":
case "shx":
case "dbf":
return FileExtension.Shapefile;
case "topojson": return FileExtension.TopoJson;
default: return null;
}
}
2.The files:
Model Code
Model
Thanks in advance,