Hi,
According to the coordinates, Mszczonowska street is at 52.132839559508824, 20.891170983827966.
(Mszczonowska, 05-090 Janki, Poland
Latitude: 52.13284 | Longitude: 20.891171), but I can’t get this location by entering pointshape in the code below.
In addition, I am trying to draw a line based on the following data, also does not get the expected result on screen.
“\ColdFront1.txt”
LINESTRING (52.132839559508824 20.8911709838279696.52.13277891365223 20.891067296445456.52.13271766617681 20.89096031310927)
@page “/work-with-ogc-services”
@using System.Collections.ObjectModel
@using ThinkGeo.Core
@using System.Text
<MapView Id=“map” @ref=“map”
Width=“100”
Height=“100”
MapViewSizeUnitType=“MapViewSizeUnitType.Percentage”
Center="@(new PointShape(52.132839559508824,20.891170983827966))"
Zoom=“15”
MapUnit="@ThinkGeo.Core.GeographyUnit.Meter">
@code {
MapView map;
Collection serverUris = new Collection { new Uri(“http://ows.mundialis.de/services/service”) };
Dictionary<string, string> parameters = new Dictionary<string, string>
{
{ “layers”, “OSM-WMS”},
{ “STYLE”, “default”},
{ “CRS”,“4326”}
};
private List<StylingModel> stylings;
private string accessId = Guid.NewGuid().ToString();
GeoCollection<Layer> Layers = new GeoCollection<Layer>();
protected override void OnInitialized()
{
string baseDirectorybaseDirectory = Path.Combine(Directory.GetCurrentDirectory(), "Data");
LineStyle lineStyle = LineStyle.CreateSimpleLineStyle(GeoColors.Black, 2, false);
InMemoryFeatureLayer inMemoryFeatureLayerColdFront = new InMemoryFeatureLayer();
inMemoryFeatureLayerColdFront.ZoomLevelSet.ZoomLevel01.CustomStyles.Add(lineStyle);
inMemoryFeatureLayerColdFront.ZoomLevelSet.ZoomLevel01.ApplyUntilZoomLevel = ApplyUntilZoomLevel.Level20;
StreamReader s = new StreamReader(baseDirectorybaseDirectory + @"\ColdFront1.txt");
LineShape lineShape2 = new LineShape(s.ReadLine());
inMemoryFeatureLayerColdFront.InternalFeatures.Add(new Feature(lineShape2));
Layers.Add("ColdFront", inMemoryFeatureLayerColdFront);
}
}
Thanks for answers