Bing Maps v8 API - loadModule
i trying load "microsoft.maps.clustering" using 'microsoft.maps.loadmodule'.
but not getting error.without clustering,test data pushpins loaded successfully.
here sample code.
mainmap = new microsoft.maps.map($(id)[0],
{
credentials: bingmapkey,
center: new microsoft.maps.location(39.393486, -98.100769),
zoom: 3
});
microsoft.maps.loadmodule("microsoft.maps.clustering", function () {
// creating sample pushpin data within map view
var pushpins = microsoft.maps.testdatagenerator.getpushpins(100, mainmap.getbounds());
var clusterlayer = new microsoft.maps.clusterlayer(pushpins, { gridsize: 100 });
mainmap.layers.insert(clusterlayer);
});
Bing Maps > Bing Maps Web Controls
Comments
Post a Comment