how to get and set layer styles
I need to make changes to a layer's styles in a worklfow. There are preconfigured styles in essentials for the layer which can be changed in the viewer using dynamic symbolization, but I am having difficulty accessing the property which defines them form the GetLayerProperty activity. According to the sdk, I should be getting a LayerStyle[] returned, but this is apparently not what is being returned. How do I access this information?
I then try to change the layer's definition to update the visualization, to no avail. I've tried setting the dynamicDefinition property with a layerDefinition json string, and I've tried the Set Layer Definition activity with the same string, but nothing works! Can I not set layer symbology in a workflow?
0
-
Hi Zack,
If you are trying to change the layer style, I would suggest using the UpdateGraphicsLayer activity to achieve what you want instead of trying to extract the LayerStyle[]. This is much easier to configure and the only difference is the symbolization will be added to a graphics layer that sits on top of the layer rather than changing the layer style. We have some pre-configured renderers that you can use to get started.
I hope this helps.
Carmen0
Please sign in to leave a comment.
Comments
1 comment