我想在Windows 10应用程序中向MapControl添加一个Pushpin,但是自Windows 8.1以来,控件似乎已经消失了。
就这么简单:
<input type="radio" name="Owner" <?php if($row['Owner'] == "A") { echo "checked"; }?> value="A">
但是不再识别Pushpin类型......
答案 0 :(得分:7)
地图控制在UWP中几乎没有变化 - 请查看Windows.UI.Xaml.Controls.Maps namespace。
至于添加图钉(POI),您可以do it in couple of ways。例如:
// get position
Geopoint myPoint = new Geopoint(new BasicGeoposition() { Latitude = 51, Longitude = 0 });
//create POI
MapIcon myPOI = new MapIcon { Location = myPoint, NormalizedAnchorPoint = new Point(0.5, 1.0), Title = "My position", ZIndex = 0 };
// add to map and center it
myMap.MapElements.Add(myPOI);
myMap.Center = myPoint;
myMap.ZoomLevel = 10;
了解更多指南visit MSDN。