mapstraction.removeMarker() function not working properly, it didn't remove marker on map

110 views Asked by At

mapstraction.removeMarker didn't remove the marker on map

It doesn't throws any exception.bt its not removed on mapstraction map.

`mapstraction.removeMarker(markers[j]);

//I will get all markers from mapstraction map, then i want to remove all
    removeAllMarkers(mapstraction.markers);
//some of them are not removed

    function removeAllMarkers(markers){
        for(var j=0; j<markers.length; j++){
            try{
                mapstraction.removeMarker(markers[j]);
            }catch(err){
            }
        }
}
0

There are 0 answers