Methods

Method for navigating to specific shape based on latitude, longitude and zoom level, you can use navigateTo method.

  • html
  • <div id="Map1">
        <ej-map></ej-map>
    </div>
  • js
  • var map = $("#Map1").data("ejMap");
    map.navigateTo();

    pan(direction)

    Method to perform map panning, you can use pan method.

  • html
  • <div id="Map1">
        <ej-map></ej-map>
    </div>
  • js
  • var map = $("#Map1").data("ejMap");
    map.pan();

    refresh()

    Method to reload the map, you can use refresh method.

  • html
  • <div id="Map1">
        <ej-map></ej-map>
    </div>
  • js
  • var map = $("#Map1").data("ejMap");
    map.refresh();

    refreshLayers()

    Method to reload the shapeLayers with updated values, you can use refreshLayers method.

  • html
  • <div id="Map1">
        <ej-map></ej-map>
    </div>
  • js
  • var map = $("#Map1").data("ejMap");
    map.refreshLayers();

    refreshNavigationControl(navigation)

    Method to reload the navigation control with updated values, you can use refreshNavigationControl method.

  • html
  • <div id="Map1">
        <ej-map></ej-map>
    </div>
  • js
  • var map = $("#Map1").data("ejMap");
    map.refreshNavigationControl();

    zoom(level, isAnimate)

    Method to perform map zooming, you can use zoom method.

  • html
  • <div id="Map1">
        <ej-map></ej-map>
    </div>
  • js
  • var map = $("#Map1").data("ejMap");
    map.zoom();

    Events

    MarkerSelected

    Triggered on selecting the map markers, you can use MarkerSelected event.

  • html
  • <div ng-controller="Map">
        <div id="container" style="width: 100%" e-markerSelected="onMarkerSelected"></div>
    </div>
  • js
  • angular.controller('Map', function ($scope) {    
        $scope.onMarkerSelected = "MarkerSelected";    
    });
     
    function MarkerSelected(){
        // Do Something
    }

    MouseLeave

    Triggers while leaving the hovered map shape, you can use MouseLeave event.

  • html
  • <div ng-controller="Map">
        <div id="container" style="width: 100%" e-mouseleave="onMouseLeave"></div>
    </div>
  • js
  • angular.controller('Map', function ($scope) {    
        $scope.onMouseLeave = "MouseLeave";    
    });
     
    function MouseLeave(){
        // Do Something
    }

    MouseOver

    Triggers while hovering the map shape, you can use MouseOver event.

  • html
  • <div ng-controller="Map">
        <div id="container" style="width: 100%" e-mouseover="onMouseOver"></div>
    </div>
  • js
  • angular.controller('Map', function ($scope) {    
        $scope.onMouseOver = "MouseOver";    
    });
     
    function MouseOver(){
        // Do Something
    }

    RenderComplete

    Triggers once map render completed, you can use RenderComplete event.

  • html
  • <div ng-controller="Map">
        <div id="container" style="width: 100%" e-rendercomplete="OnRenderComplete"></div>
    </div>
  • js
  • angular.controller('Map', function ($scope) {    
        $scope.OnRenderComplete = "RenderComplete";    
    });
     
    function RenderComplete(){
        // Do Something
    }

    Panned

    Triggers when map panning ends, you can use Panned event.

  • html
  • <div ng-controller="Map">
        <div id="container" style="width: 100%" e-panned="onPanned"></div>
    </div>
  • js
  • angular.controller('Map', function ($scope) {    
        $scope.onPanned = "Panned";    
    });
     
    function Panned(){
        // Do Something
    }

    ShapeSelected

    Triggered on selecting the map shapes, you can use ShapeSelected event.

  • html
  • <div ng-controller="Map">
        <div id="container" style="width: 100%" e-shapeSelected="onShapeSelected"></div>
    </div>
  • js
  • angular.controller('Map', function ($scope) {    
        $scope.onShapeSelected = "ShapeSelected";    
    });
     
    function ShapeSelected(){
        // Do Something
    }

    ZoomedIn

    Triggered when map is zoomed-in, you can use ZoomedIn event.

  • html
  • <div ng-controller="Map">
        <div id="container" style="width: 100%" e-zoomedIn="onZoomedIn"></div>
    </div>
  • js
  • angular.controller('Map', function ($scope) {    
        $scope.onZoomedIn = "ZoomedIn";    
    });
     
    function ZoomedIn(){
        // Do Something
    }

    ZoomedOut

    Triggers when map is zoomed out, you can use ZoomedOut event.

  • html
  • <div ng-controller="Map">
        <div id="container" style="width: 100%" e-zoomedOut="onZoomedOut"></div>
    </div>
  • js
  • angular.controller('Map', function ($scope) {    
        $scope.onZoomedOut = "ZoomedOut";    
    });
     
    function ZoomedOut(){
        // Do Something
    }