【问题标题】:How to display Pin's Label (on a Map) without clicking on it Xamarin.Forms pcl如何在不单击的情况下显示 Pin 的标签(在地图上) Xamarin.Forms pcl
【发布时间】:2017-05-11 16:59:09
【问题描述】:
var pin = new Pin
{
    Type = PinType.Place,
    Position = new Position(currentlat, currentlong),
    Label = "My Current Location ",
    Address = "My Current Location "
};
map.Pins.Add(pin);

在这里,当我单击 pin 时,我可以看到标签地址。但我想在别针上看到标签而不点击它..

【问题讨论】:

  • 有什么解决办法吗?

标签: c#-4.0 xamarin.forms


【解决方案1】:

您可以使用 Map.SelectedPin 属性的属性。

只需设置 Map.SelectedPin = Pins[i];

这将在您的 pin 上显示一个标签,而无需单击它。

【讨论】:

猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2021-11-17
  • 2019-10-07
  • 1970-01-01
  • 1970-01-01
  • 2018-09-06
  • 1970-01-01
相关资源
最近更新 更多