【问题标题】:Set a map's top-left and bottom-right coordinates设置地图的左上角和右下角坐标
【发布时间】:2011-04-14 06:16:42
【问题描述】:

我在 Bing 地图控件上有固定数量的图钉,并且需要设置地图的中心和缩放级别,以便我看到所有图钉。换句话说,知道最左边、最右边、最上面和最下面的引脚,我如何调整视图以便我看到它们?

ZoomLevel 值相对于缩放/坐标是否有意义?

【问题讨论】:

    标签: windows-phone-7 bing-maps


    【解决方案1】:

    假设 Points 是您的图钉集合,而 map 是您的地图名称 :)

    var x = from l in Points
            select l.Location;
    
    map.SetView(LocationRect.CreateLocationRect(x));
    

    【讨论】:

      猜你喜欢
      • 2013-12-22
      • 2016-10-18
      • 2015-09-22
      • 2021-10-30
      • 1970-01-01
      • 2014-10-26
      • 1970-01-01
      • 1970-01-01
      • 2018-12-29
      相关资源
      最近更新 更多