Hi all,
I have built two FeatureLayer (3.14) in client-side from JSON objects .
They contains both simple points, one with some yellow circle and one with a star.
I have set labelingInfo for one as show in the image above. It works fine.
Now, I have tryed to print the map using the ESRI Export Web Map Service
and the image obtained doesn't have labels.
I call the service with this request, any suggest????
f=json&Format=PNG32&Layout_Template=MAP_ONLY&Web_Map_as_JSON=
"mapOptions": {
"showAttribution": false,
"extent": {
"xmin": 1378137.0264387086,
"ymin": 5475499.428862644,
"xmax": 1385780.729267216,
"ymax": 5483143.131691152,
"spatialReference": {"wkid": 102100}
}
},
"operationalLayers": [
{
"url": "https://services.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer"
},
{
"featureCollection": {
"layers": [
{
"layerDefinition": {
"typeIdField": "",
"objectIdField": "id",
"name": "Concorrenza",
"drawingInfo": {
"renderer": {
"type": "simple",
"symbol": {
"color": [247,168,0,255],
"size": 13,
"angle": 0,
"xoffset": 0,
"yoffset": 0,
"type": "esriSMS",
"style": "esriSMSCircle"
}
},
"labelingInfo": [
{
"labelExpression": null,
"labelExpressionInfo": {
"value": "{id}"
},
"format": null,
"fieldInfos": null,
"useCodedValues": false,
"maxScale": 0,
"minScale": 0,
"where": null,
"sizeInfo": null,
"labelPlacement": "esriServerPointLabelPlacementCenterCenter",
"symbol": {
"color": [0,0,0,255],
"type": "esriTS",
"horizontalAlignment": "center",
"angle": 0,
"xoffset": 0,
"yoffset": 0,
"text": "",
"rotated": false,
"kerning": true,
"font": {
"size": 9,
"family": "Arial"
}
}
}
]
},
"type": "Feature Layer",
"fields": [
{
"name": "id",
"alias": "ID",
"type": "esriFieldTypeOID"
},
{
"name": "nome",
"alias": "NOME",
"type": "esriFieldTypeString"
},
{
"name": "via",
"alias": "VIA",
"type": "esriFieldTypeString"
},
{
"name": "cap",
"alias": "CAP",
"type": "esriFieldTypeString"
},
{
"name": "citta'",
"alias": "Citta'",
"type": "esriFieldTypeString"
},
{
"name": "prov",
"alias": "PROV",
"type": "esriFieldTypeString"
}
],
"geometryType": "esriGeometryPoint",
"types": [],
"capabilities": ""
},
"featureSet": {
"features": [
{
"geometry": {
"x": 12.4024018102496,
"y": 44.0992129263624,
"spatialReference": {
"wkid": 4326
}
},
"attributes": {
"id": 1
}
},
{
"geometry": {
"x": 12.395513230862,
"y": 44.0937650870184,
"spatialReference": {"wkid": 4326}
},
"attributes": {
"id": 2
}
}
],
"geometryType": "esriGeometryPoint"
},
"nextObjectId": 6
}
]
}
},
{
"featureCollection": {
"layers": [
{
"layerDefinition": {
"objectIdField": "id",
"name": "PSP",
"drawingInfo": {
"renderer": {
"symbol": {
"size": 16,
"imageData": "iVBORw0KGgoAAAANSUhEUgAAABYAAAAUCAYAAACJfM0wAAAAAXNSR0IB2cksfwAAAAlwSFlzAAAOxAAADsQBlSsOGwAAAmVJREFUOI2t1F9Ik1EYx/HvlvMotpxJ0SpsFDXFQKGGJKWmlndaF4aVlSFCRmEKEnVhEo7+GER2VUQML8qCUG9SM8OLsISgVV44sND+sAR5dajUo23rQqM1Npm05+rw/p73wznPe3hjWF6tBGYiaYxZJnwVOBNV2Gw2p2tud7VAIzARNXhvirvygRs9cAC4FzX4h3C4JBM8MxzvH4kevK3dyboPVyC3kWzABEz9N3wsiyrLWkhPgdw0fO1OioHWSOFDVrOy1RaxOz6WVYFNPe9kc2EG6IDyHAwmI7fy0tT5wJ5pkQl7m3rtFukHugLhjlGN7FMOybKuxl9/EL1+MSjcDpmWhfUuK3hmMXm9YgKY98KFh/g1wQfSB/QE73hORM4Bz1wajvefkaYyNhrj/j2i2QQn8xfWk7N4T99hXBO8SqkjIvIy1Cj+1FMgo6WX1r4hTE/qiLWuJza46c1HpovtGNzCIFApIpOBebiP5wb2j2iqKbVeLk7dhcSEv+E3DWwNGIE64GYoYKlb4c+ziMeyAX9iAjqAXz6I0S+MY58VX6+LT+FeXvK6JZuoKNmBzg+8GEKrcZDgqEa/cwuGinz0ySaq2gbpXC68pttJamMpXHrM+PVOFEq1FNnl7OUyfuakYmzuoAAwAPMRw9mbKB3+jq7iNtMDY7iAckS+CNxvaOORzcJWp5t4pVSBiHRHDCfFcXRW8A6M0QzYAd9iNKwJtv5RdQ2kJt8iJ7pcRAwnPh9VySj2IPIqRD4nIrVKqZ4ul9wAVgDeSGCjiGQBnnAnAlgcwVsgiaB/dDj461JgUI2HevgbQ+7ZsLv3fOwAAAAASUVORK5CYII=",
"width": 16,
"type": "esriPMS",
"contentType": "image/png",
"url": "cee6af51be187ef858113fdceb992826",
"height": 15
},
"type": "simple"
}
},
"type": "Feature Layer",
"fields": [
{
"name": "id",
"alias": "id",
"type": "esriFieldTypeOID"
}
],
"geometryType": "esriGeometryPoint",
"capabilities": ""
},
"featureSet": {
"features": [
{
"geometry": {
"x": 12.40899,
"y": 44.092698,
"spatialReference": {"wkid": 4326}
},
"attributes": {
"id": 100
}
}
],
"geometryType": "esriGeometryPoint"
},
"nextObjectId": 101
}
]
}
}
],
"baseMap": [],
"exportOptions": {
"outputSize": [2060,1400],
"dpi": 300
},
"layoutOptions": {}
}
Thanks
Massimiliano
Have you solved this issue? I have the same problem the label of featureCollection does not display in the print result.
Hi,
no I haven't, the project ended shortly after and I never investigated again.
Massimiliano
Could you share a codepen or simple repro case? What is the version of the Print Service you are using?