Select to view content in your preferred language

How to snap to "oneself" at start/end point.

1820
8
05-24-2012 08:45 AM
ScottGowan
Occasional Contributor
Greetings all,

Is there a way to snap an existing feature's end point to its starting point without manually moving one of the vertices?

I'm currently editing/cleaning up building footprints in a line feature class to eventually create building polygons.  I've created a topology and am now editing all leftover dangles and overshoots.  Most building footprints consist of a single feature.  Where I have a small gap at a corner,  the start and end vertices of the feature need to be snapped together. I've tried to running the snap tool from the editing toolbox and nothing happens, I assume because the feature won't snap to itself.  ( I also tried the trim tool before creating the topology which didn't work either and I'm assuming for the reason that a feature cannot be used to trim itself. )  In snap options classic, Edit sketch vertices is toggled "on". When using the fix topology error tool then the snap option I get "Snap dangle error failed"

My current method is to set the snapping environment appropriately, then for each situation where there's a gap, manually move one of the vertices so it snaps to the other.  Creating a coverage would do this but isn't there a better way other than creating a coverage then bringing it back into to a feature
class?

Scott
Tags (2)
0 Kudos
8 Replies
TrishRice
Deactivated User
You can use the Feature Vertices to Point tool in Data Management toolbox to create points at the beginning, then snap your ends to those points.  Alternately it would probably work to create a duplicate of your line file and snap to that.
0 Kudos
JohnSobetzer
Honored Contributor
I'm probably missing something and if so I apologize but it looks like you have two different "snap" issues.  In the case of manual editing with lines, if you are adding to a line with the sketch tool you need to have The Edit Sketch box in the snapping environment checked to get it to snap to itself, but if you are selecting and moving a pre-existing vertice then up in the Layer window you need to have your layer's Vertex or End box's checked.  If the case of automatic cleanup, you might consider using the Integrate tool, which functions a bit like the coverage clean in terms of making vertice's coincident.  Do it on a copy since the changes are made in the layer instead of producing a new one, and you may want to play around with different tolerances to get your vertices to "snap" without moving others too much.  One other thought, there are snap, sticky move and tolerance settings that affect your work, and if one of them is set large you have to move your vertice beyond that tolerance to get it to move.  The Editor - Options settings for snap and sticky move are in pixels and hence how closely you are zoomed in can affect your snap/sticky "distance".
0 Kudos
ScottGowan
Occasional Contributor
You can use the Feature Vertices to Point tool in Data Management toolbox to create points at the beginning, then snap your ends to those points.  Alternately it would probably work to create a duplicate of your line file and snap to that.


Thanks for the idea Trish.  I've spent so much effort trying to make the proper tool function that I wasn't thinking of workarounds.

I tried both of your suggestions and still no luck getting the topological error tool to snap to the extra features.  I can get it to snap to a feature 10 metres away on the same layer and the addtional layers from your suggestion, but not the vertex that's less than 1 metre away.  It keeps returning "Snap dangle error failed."  It's almost as if it searches, finds the other end point of the current feature first, which it can't snap to, then returns the error before searching and finding the vertex of the additional layer.  If I create a new seperate feature within the specified snap distance I can successfully snap to that using the tool.    Just a bug witht the Fix Topology Error Tool I suppose.

Thanks for your suggestions and time.

Scott
0 Kudos
ScottGowan
Occasional Contributor
I'm probably missing something and if so I apologize but it looks like you have two different "snap" issues.  In the case of manual editing with lines, if you are adding to a line with the sketch tool you need to have The Edit Sketch box in the snapping environment checked to get it to snap to itself, but if you are selecting and moving a pre-existing vertice then up in the Layer window you need to have your layer's Vertex or End box's checked.  If the case of automatic cleanup, you might consider using the Integrate tool, which functions a bit like the coverage clean in terms of making vertice's coincident.  Do it on a copy since the changes are made in the layer instead of producing a new one, and you may want to play around with different tolerances to get your vertices to "snap" without moving others too much.  One other thought, there are snap, sticky move and tolerance settings that affect your work, and if one of them is set large you have to move your vertice beyond that tolerance to get it to move.  The Editor - Options settings for snap and sticky move are in pixels and hence how closely you are zoomed in can affect your snap/sticky "distance".


Hi John,

I'm not actually adding new features and I'm aware of the Edit Sketch Box options.  I've used Integrate to get to the point I'm at now without creating too many extra errors as well as investigated and set all the settings you've mentioned.  I'm simply cleaning up the mess that's left over.  The Fix topolgy Error Tool would probably be the fastest tool to use if it worked correctly but at this point I'm going to plug away at moving each vertex using the edit tool.  I believe it to be a bug with the tool but hopefully someone can prove me wrong.

Thanks for the help.

Scott
0 Kudos
by Anonymous User
Not applicable
All the tools you have described are designed to work against other features. Its easy for a human to make the call on what the two end points should do when you're trying to trim or snap dangles from the same feature, but less so for tools or a topology fix that has no guidelines. This could be improved.

You could try the Feature To Polygon GP tool which will create polygons from your lines and snap dangles with a tolerance. In the case of undershoots the two ends are moved to a midpoint. If you need to keep the building lines, you could then use the Polygon To Line GP tool, which means you wont see overshoots.
0 Kudos
ScottGowan
Occasional Contributor
All the tools you have described are designed to work against other features. Its easy for a human to make the call on what the two end points should do when you're trying to trim or snap dangles from the same feature, but less so for tools or a topology fix that has no guidelines. This could be improved.

You could try the Feature To Polygon GP tool which will create polygons from your lines and snap dangles with a tolerance. In the case of undershoots the two ends are moved to a midpoint. If you need to keep the building lines, you could then use the Polygon To Line GP tool, which means you wont see overshoots.


Hi Sean,

The Feature to Polygon tool is what I started with initially, however, I was missing too many polygons in the end to use the result so I wanted to go through the entire data set to be sure I got the best result I could.  I experimented with various processes and tolerances and decided the best result would be to manually edit the line feature class from a certain point before recreating polygons.  I've zipped through over 3200 errors fairly quickly with my own workflow but was wondering why I couldn't get the toplogy error tool to work.  Now I know it just won't do what I expected.

Thanks,
Scott
0 Kudos
by Anonymous User
Not applicable
Actually also try the Split Line At Vertices tool. This will create separate features from the building lines (essentially creating two-point line features) which means all the topology and snap tools should work.
0 Kudos
TrishRice
Deactivated User
Thanks for the idea Trish.  I've spent so much effort trying to make the proper tool function that I wasn't thinking of workarounds.

I tried both of your suggestions and still no luck getting the topological error tool to snap to the extra features.  I can get it to snap to a feature 10 metres away on the same layer and the addtional layers from your suggestion, but not the vertex that's less than 1 metre away.  It keeps returning "Snap dangle error failed."  It's almost as if it searches, finds the other end point of the current feature first, which it can't snap to, then returns the error before searching and finding the vertex of the additional layer.  If I create a new seperate feature within the specified snap distance I can successfully snap to that using the tool.    Just a bug witht the Fix Topology Error Tool I suppose.

Thanks for your suggestions and time.

Scott


Are you still using the Snap tool in the Editing toolbox?  These steps worked for me on a new experimental layer.  I drew two line features with the ends off from the starting points by 2.35 feet and 0.28 feet.  I used Feature Vertices to Points to make points at the starts.  Then with Snap I used End type and 3 feet distance (this is the Snap in the Editing toolbox, not a topological snap).
0 Kudos