AnsweredAssumed Answered

How to show center point icon on a Map?

Question asked by S.h.a.n.e on Jan 31, 2018
Latest reply on Jan 31, 2018 by S.h.a.n.e

Hi, I'm showing a map from an MVC application using the js 4.6 api. The SceneView displays fine, at the correct zoom level and center point:


var view = new SceneView({
container: "map_canvas", map: map, scale: 50000, center: [@Model.LONGITUDE, @Model.LATITUDE]


I also need to display an icon at the center point of the map, with a label, which is clickable to show its attributes. I tried to do this using:


var features = [{

geometry:{type: "point",x: @Model.LONGITUDE,y: @Model.LATITUDE},

attributes:{ObjectID: 1,DepArpt: "KATL",MsgTime:,FltId: "UAL1"}



var pointsLayer = new FeatureLayer({
source: features




I don't get any error but the point doesn't show up. Any help would be appreciated. Thanks!


Here's the rest of the code:


<link rel="stylesheet" href="">
<script src=""></script>

#map_canvas img {
max-width: none;

<div id="map_canvas" style="height: 550px;"></div>

"dojo/dom", "dojo/on", "dojo/domReady!"
], function (Map, SceneView, Draw, Point, SimpleMarkerSymbol, SimpleLineSymbol, PictureFillSymbol, CartographicLineSymbol, Graphic, Color, dom, on) {
var map = new Map({
basemap: "hybrid", //streets, satellite, hybrid, topo, gray, dark-gray, oceans, osm, national-geographic
ground: "world-elevation",
sliderStyle: "large"