AnsweredAssumed Answered

Why doesn't my layer show labels?

Question asked by bpstewar on Mar 14, 2012
Latest reply on Nov 15, 2016 by Amoor_38
I'm adding a feature layer to an esri.map, and I can't understand why labels aren't showing up. This is the layer I'm trying to add, and it has a labeling definition. Am I missing something in the definition of the map? Or of the feature layer?

        var map = new esri.Map("map", { extent: esri.geometry.geographicToWebMercator(initialExtent), slider: true, nav: false });         dojo.connect(map, "onLoad", initSelectToolbar);            var baseMapLayer = new esri.layers.ArcGISTiledMapServiceLayer("http://server.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer");         map.addLayer(baseMapLayer);      //Add regional summation data   var content = "<b>Region</b>: ${Region_1}" +                         "<br><b>Value USD(Millions)</b>: ${SUM_MAX_TotalAmt}" +                         "<br><b>Number of Projects</b>: ${SUM_COUNT_ProjectID}";   var infoTemplate = new esri.InfoTemplate("${FIELD_NAME}", content);     featureLayer = new esri.layers.FeatureLayer("http://maps4.arcgisonline.com/ArcGIS/rest/services/World_Bank/WB_World_Bank_Projects/MapServer/1",{           mode: esri.layers.FeatureLayer.MODE_ONDEMAND,           infoTemplate: infoTemplate,     outFields: ["*"]             });  map.addLayer(featureLayer);

Outcomes