ChangeMarkupStyle command not working as expected
I am trying to use the ChangeMarkupStyle command in a workflow to set the color of a markup I am creating. It sort of works but not quite. Here is a snippet of the workflow._img_ alt="User-added image" src="https://latitudegeo--c.na53.content.force.com/servlet/rtaImage?eid=906f2000000XcCR&feoid=Body&refid=0EMf2000000YEBZ"_/_img_
Command Name "ChangeMarkupStyle"
Command Parameter "{""color"": [0,0,0,255], ""type"": ""esriSFS"",""style"": ""esriSFSForwardDiagonal"", ""outline"": {""color"": [0,0,0,255], ""width"": 2, ""type"": ""esriSLS"", ""style"": ""esriSLSSolid""}}"
It works if the Mark Up (Draw Tool) is set to Polygon in the viewer, however by default it is set to Point in which case the style does not change to the style I am after. Is there a way to set the Draw mode to polygon or the markupType to Polygon before I run the style change so that it will work. I noticed there is an event to listen for a MarkupTypeChangeEvent but no command to ChangeMarkupType ????
Thanks.
0
-
Hi Brian,
Would the CreateMarkupStyleView command work or are you trying to not involve the user picking the type?
Regards,
Wayne Richard
Latitude Geographics Group Ltd.
Head Office: 300 – 1117 Wharf Street Victoria, BC Canada V8W 1T7
Tel: (250) 381-8130 | Fax: (250) 381-8132 | wrichard@latitudegeo.com
Developers of Geocortex web-based mapping software | www.geocortex.com
An Esri Platinum Business Partner0 -
Hi Wayne,
I'm trying to set the style without involving the user. I can kind of do what I am after using Update Graphics Layer also e.g.
_img_ alt="User-added image" src="https://latitudegeo--c.na53.content.force.com/servlet/rtaImage?eid=907f2000000Xecg&feoid=Body&refid=0EMf2000000YEGA"_/_img_
However, it doesn't quite work again as when you try to Edit the graphics using the Draw Tool it throws an error?
But it would be good to get back to the first solution and have a method to change the markup type then set the style.0 -
Hi Brian,
The ChangeMarkupStyle command implementation will only change the style for the currently selected type of markup - this command was intended for use interactively, not from a workflow.
I'm not sure if this will work, but in your second method, I think if you set the Remove All Features to False and leave FeatureSet blank in the Update Graphics Layer activity, you can update the renderer for the drawings layer only and should still be able to edit them.
Regards,
-Malcolm0
Du måste logga in om du vill lämna en kommentar.
Kommentarer
3 kommentarer