设置地图的左上角和右下角坐标

时间:2010-09-19 05:10:32

标签: windows-phone-7 bing-maps

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

ZoomLevel值是否相对于缩放/坐标具有任何重要性?

1 个答案:

答案 0 :(得分:4)

假设Points是你的Pushpins集合,map是地图的名称:)

var x = from l in Points
        select l.Location;

map.SetView(LocationRect.CreateLocationRect(x));
相关问题