Maps Bing Map V8群集传递实时数据
我只是从Bing地图开始。查阅了官方文件中的几个例子 来自 当我在ClusterLayer中传递上述对象时,我得到以下错误Maps Bing Map V8群集传递实时数据,maps,bing-maps,Maps,Bing Maps,我只是从Bing地图开始。查阅了官方文件中的几个例子 来自 当我在ClusterLayer中传递上述对象时,我得到以下错误 Uncaught TypeError: i[t].getLocation is not a function(…) 您必须循环浏览数据并将其转换为图钉。下面是一个代码示例: var pins = []; for(var i = 0;i < mapData.length;i++){ var pin = new Microsoft.Maps.Pushpin(n
Uncaught TypeError: i[t].getLocation is not a function(…)
您必须循环浏览数据并将其转换为图钉。下面是一个代码示例:
var pins = [];
for(var i = 0;i < mapData.length;i++){
var pin = new Microsoft.Maps.Pushpin(new Microsoft.Maps.Location(mapData[i].Latitude, mapData[i].Longitude));
//Store the original data object in the pushpins metadata so that you can access other properties like Name.
pin.metedata = mapData[i];
pins.push(pin);
}
//Now "pins" is an array of pushpins. Add them to the map or to the clustering layer.
var引脚=[];
对于(var i=0;i
Uncaught TypeError: i[t].getLocation is not a function(…)
var pins = [];
for(var i = 0;i < mapData.length;i++){
var pin = new Microsoft.Maps.Pushpin(new Microsoft.Maps.Location(mapData[i].Latitude, mapData[i].Longitude));
//Store the original data object in the pushpins metadata so that you can access other properties like Name.
pin.metedata = mapData[i];
pins.push(pin);
}
//Now "pins" is an array of pushpins. Add them to the map or to the clustering layer.