AnsweredAssumed Answered

Showing Multiple Labels

Question asked by cadgis on Feb 29, 2016
Latest reply on Mar 7, 2016 by sarahclark

How can I place multiple labels in a parcel feature layer.  My following function adds single attribute field as label  as charm. Dont know how to add multiple attributes as labels.  Appricate any help.

=========================================

 

function showLables(color, fsize, lblLayerID, LayerName, LabelField) {

    color = new esri.Color(color);

    var labelField  = LabelField;

    statesLabel = new esri.symbol.TextSymbol().setColor(color);

    statesLabel.font.setSize(fsize);

    statesLabel.font.setFamily("arial");

    var renderer = new esri.renderer.SimpleRenderer(statesLabel);

    var labels = new esri.layers.LabelLayer({ id: lblLayerID });

    labels.addFeatureLayer(LayerName, renderer, "{" + labelField  + "}");

    app.map.addLayer(labels);

}

 

Thank you

Outcomes