Copy polygon into create new feature?
I'm wondering if there is anyway for a user to select an existing polygon (from a non-feature layer) and then paste the polygon into the feature layer via the "Create New Feature" tool, or somthing similar?
I have a City Boundary, which outlines all the "inside City limits" areas. My Police Department needs to add these areas to their "beats" and "reporting sectors". I have a feature layer created and I can allow them to draw a polygon, and even snap to City Boundary, but it would great if they could just select a polygon and paste it into the feature layer.
Thoughts?
0
-
Hi Mike,
Not sure if I’m getting this right but could you think to achieve that with a workflow?
User could select a feature and workflow could add geometry to your feature layer with “AddFeature”. If user needs to add additional info they can be added with an Update feature … just an idea …0 -
Right, that's where my searches yesterday led me as well. I'm brand new to GE (acutally to GIS altogether) so Google has been my best friend. I'm basically living in the GE help documents today. 0 -
@Mike,
I provided some edit tools for the HTML viewer, assuming this is the viewer you are working with (not the silverlight one).
the link can be found here..
https://support.geocortex.com/essentialsGSCCodeGallery?sub-nav=codegall&main-nav=essentials&#!/feedtype=SINGLE_ARTICLE_DETAIL&dc=Geocortex_Essentials_cg&criteria=BESTANSWERS&id=kA4600000008V9H
and look for the copy tool, which should have an example of how to copy from the graphic layer to the feature layer.
or I can send you the workflow .xaml file if you PM me.. :)
regards
Gareth0 -
I created a workflow myself that copied a feature based on a users selection and pasted it into another feature, however I found it wouldn't paste empty geometry, it always needed the attributes assigned in the workflow. 0 -
Hi Sylvia,
This could be related to the constraint that your database table have (mandatory fields).
If you cannot change database constraints you could adjust workflow in following way:
Ask the user to select geometry, keep geometry into a workflow variable, ask the user the additional info/attributes, once that attributes are entered do a single insert with both geometry and attributes…0 -
Gareth,
Thanks a ton. I happened upon that package yesterday and have been checking it out. I'm looking at the help documents on the various actions to learn how it works.0 -
Apparently I'm really missing something. I'm able to trigger the workflow with a custom button using "RunWorkflowById" and the ID of the workflow, prompted to draw a rectangle, click Ok, and then the map just refreshes.
Is there a "step through" type troubleshooting feature or anything?0 -
Mike,
If I get some time today, I'll see if I can tweak that more complex workflow so it basically selects graphics and copies to a single map layer.
It's hard to step through the workflow designer when it relies on user interaction..0 -
Anything would help at this point. Your workflow looks very well put together, and also might be a little overkill for what I'm trying to accomplish. I can predefine the "copy from" and "copy to" layers in the attributes of the work flow. We have polygons representing our City Boundary (enclaves of course...), and the user just needs to copy the polygon, paste it into their "reporting" layer, and assign a 4 digit number. 0 -
Mike,
Try this one on for size...
hope it helps. Apologies for the delay - we had a our Melbourne cup long weekend :)
https://drive.google.com/file/d/1iRxwRARfruUsgCBJhHgaUJq6RJY8u4rN/view?usp=sharing0 -
Gareth, in your simple workflow in the link above, where do you refference the feature sevices/map services to copy from and to? 0 -
Beck,
In the display form I give the option to select a From, and a To layer.. Although it really hard codes to selecting only from the from the Roads, or Property layer: (urlRoadsREST, and urlPropertyREST), to the urlObsAreaFeatureLayer, who's url path is also defined in the variables section...
does that help?0 -
Gareth, can you have the choice of what you want it to Copy To, or only copy to the 1 defined feature (in your example urlObsAreaFeatureLayer)? Does my question make sense? Happy to discuss further via email if you'd like. 0
Please sign in to leave a comment.
Comments
13 comments