News

ArcWatch: GIS News, Views, and Insights

April 2012


Use the Snap Geoprocessing Tool to Automate Editing

By Colin Childs
Esri Instructor

The Snap geoprocessing tool in ArcGIS for Desktop, Standard and Advanced, can speed up editing tasks, saving you time. Snapping ensures that features you create are connected to each other, making your edits more accurate.

When you use interactive snapping during an editing session in ArcMap, your pointer will jump, or snap, to edges, vertices, and other geometric elements when the pointer is within the snapping tolerance specified for these features. You set snapping rules to control whether input vertices are snapped to the nearest vertex, edge, or endpoint within a snapping tolerance.

Using the Snap geoprocessing tool, located in the Editing toolset of ArcToolbox, multiple feature elements can be snapped accurately in relation to the locations of other features. The Snap geoprocessing tool automatically performs the work you would otherwise have done interactively. The tool can act on all features or only selected ones. It will also move source points or vertices to coincide exactly with target vertices, edges, or endpoints. This example will illustrate how to set up and use the Snap geoprocessing tool. In this scenario, you have imported parcel boundary lines for a subdivision but discover these new lines are not connected to existing parcel boundary lines. Rather than manually connecting them, it will be easier to use the Snap geoprocessing tool to connect all the unconnected parcel lines in a single process.

Step 1

First, select all the unconnected parcel boundaries using a spatial or attribute selection method.


Select parcel boundary lines.

Next, start an edit session by right-clicking the parcel boundary layer in the table of contents and choosing Start Editing from the Edit features choice.

Because you are using the Snap geoprocessing tool while in an edit session, you will be able to undo any changes made to features by the tool. This means you can fix changes the tool may cause if an incorrect snap tolerance or snap environment was set.

Step 2

Locate the Snap geoprocessing tool in the Editing Tools toolset located in ArcToolbox. Hint: You could also use the Search window to find the Snap geoprocessing tool.


Use Search to locate the Snap geoprocessing tool.

Double-click on the tool to launch it.

Step 3

The Snap tool dialog has an option for specifying the input features whose vertices will be snapped to the vertices, edges, or endpoints of other features. In the example below, the parcel lines should be snapped to associated parcel lines within a snap distance.


Specify the input features to snap.

Step 4

With input features to snap specified, next specify one or more snap environments that will enable snapping when the tool is executed.

Using the drop-down arrow to the right of the Snap Environment tool parameter, choose a layer for the first snap environment. A new snap environment is added to the dialog. Setting up snap environments defines the rules that control whether input feature vertices are snapped to the nearest vertex, edge, or endpoint of the intended snap features within the snap distance.

Finish setting the snap environment by setting the type and distance to be used for the environment just created. Setting the type specifies the features that input feature vertices can be snapped to. Next, specify the distance within which the input feature vertices will be snapped to the nearest vertex, edge, or endpoint.

Setting Type to EDGE snaps input feature vertices to feature edges. Setting Type to END snaps input feature vertices to feature ends. In the example, three environments have been set: two EDGE type and one END type.


Type and Distance Variations for Snap Environments

Step 5

Finally, execute the tool by clicking OK on the Snap tool dialog.


Snap tool executing—Notice the different snap environment settings used.

In this example, when the tool finished executing, parcel line ends were snapped to coincident parcel line edges within 20 feet of each other.

Parcel Lines Snapped to the Edges of Associated Parcel Lines within 20 Feet
Parcel Lines Snapped to the Edges of Associated Parcel Lines within 20 Feet

Using the Snap geoprocessing tool with snap environments saves a significant amount of time by snapping multiple features in one pass versus snapping individual unconnected features one at a time.

 
Contact Us | Privacy | Legal | Site Map