AnsweredAssumed Answered

Using labels/labelingInfo with MapImageLayer fails

Question asked by kevinhaeni on Jul 9, 2018

I have a MapImage Layer defined as follows:


this.layer = new MapImageLayer(this.mapServiceUrl, {
    outFields: ['VC_STAT_CODE', 'ID'],
    sublayers: [
            id: 0,
            visible: true,
            popupTemplate: template,
            labelsVisible: true,
            labelingInfo: [{
                labelExpression: "[ID]",
                labelPlacement: "below-right",
                symbol: {
                    type: "text"// autocasts as new TextSymbol()
                    color: "white",
                    font: {
                        size: 8,
                    backgroundColor: [0, 0, 0, 0.5],
                minScale: 0,
                maxScale: 0

It does work fine in development (ArcGIS Server 10.5.1), however, it fails in production (ArcGIS Server 10.5). The whole layer is not being load and we are getting the following error:



  1. {name: "dynamiclayer:getImageUrl-error", message: "Unable to create image url", details: {…}}
    1. message:"Unable to create image url"
    2. name:"dynamiclayer:getImageUrl-error"


As soon as I remove the labelingInfo and labelsVisible field, the layer is again being loaded (ofc without labels).


Is there any issue with labels and arcgis server 10.5?


The MapService/layers are the same on both our servers.