Jill, did you ever resolve this? I'm experiencing the same problem. Steve
Hi,Has there been a definitive listing of the limitations of Export Web Map yet?Specifically, I'm having trouble exporting a map that contains a graphics layer symbolized using a unique value renderer.I'm getting a similar error: Error executing tool.: Layer "graphicsLayer2": Field 'pointType' not part of schema for this feature collection. Where the field 'pointType' contains the value to be rendered on.Thanks!Jill
import json jsonMap = json.loads(webMapAsJson) # -- so you can manipulate the json if jsonMap.has_key("operationalLayers"): # -- to get in the operational layer array : for operationalLayer in jsonMap["operationalLayers"]: #-- for each operational layer : if operationalLayer.has_key("featureCollection"): #-- That would be a graphicsLayer modifyTransparencyInGraphicsLayers(operationalLayer) # -- Send to a function to modify the json (this remove transparency in my case) outputJson = json.dumps(jsonMap ) # -- then you reencode your jsonMap to json result = arcpy.mapping.ConvertWebMapToMapDocument(outputJson , templateMxd) # -- Finally you can get back to the method described in the tutorial def modifyTransparencyInGraphicsLayers(operationalLayer): # -> Modify Tranparency for 'GraphicLayers' if operationalLayer["featureCollection"].has_key("layers"): for operationalLayersGraphicsLayerLayer in operationalLayer["featureCollection"]["layers"]: if operationalLayersGraphicsLayerLayer.has_key("featureSet"): if operationalLayersGraphicsLayerLayer["featureSet"].has_key("features"): for graphicsLayerParams in operationalLayersGraphicsLayerLayer["featureSet"]["features"]: if graphicsLayerParams.has_key("symbol"): if graphicsLayerParams["symbol"].has_key("color"): if len(graphicsLayerParams["symbol"]["color"]) == 4: graphicsLayerParams["symbol"]["color"][3] = 255 if graphicsLayerParams["symbol"].has_key("outline"): if graphicsLayerParams["symbol"]["outline"].has_key("color"): if len(graphicsLayerParams["symbol"]["outline"]["color"]) == 4: graphicsLayerParams["symbol"]["outline"]["color"][3] = 255 return operationalLayer
2. does not support a point with ESRI.ArcGIS.Client.Symbols.TextSymbol
Layer "graphicsLayer1": Field 'newID' not part of schema for this feature collection.
1. dose not support a polygon with a transparency2. dose not support a point with ESRI.ArcGIS.Client.Symbols.TextSymbol3. mix of geometry types
Yes that is the issue. The black back ground color is used as default since alpha values of 0 in the color definitions. Whta is your solution to fix it? Thanks, George
I think I need more specifics on exactly what doesn't work. I can see that the graphics layers are read correctly (they show some features in southern Texas), but many of them appear to have alpha values of 0 in the color definitions. For example, the outlines in your middle graphics layer. Those are treated as null colors in the output. Is that the problem -- that the graphics layers don't appear in your output?
I need to see the Python code.
If you pass along the JSON generated by your request, I can have a look and figure out what's wrong.
Membros conectados podem postar, seguir atualizações e mais. Novo aqui? Registre uma conta gratuita.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.