Adding and connecting data and tools
Adding data and tools
When data is added to a model, a data variable is created in the model. Data variables contain a description of the data, not the data itself. The value (the path to the dataset) can be viewed or changed by double-clicking the variable to open its dialog box. In addition, ModelBuilder stores other descriptive information about data variables, such as spatial extent, field information, and coordinate system. This information can be refreshed by validating the model.
When a tool is added to a model, an output variable is created in the model. Both the tool and the output variable are empty (without color) when added, as required parameters for the tool are unspecified. Once the required tool parameters are specified, the tool variable changes to a yellow color, indicating the process is ready to run.
There are two ways to add data and tools to a model:
Using the Add Data tool
Click the Add Data tool on the ModelBuilder toolbar.
- Alternatively, click Insert > Add Data or Tool.
- Browse to and choose the data or tool and click Add.
Drag and Drop
- Browse to the data or tool in the Catalog window.
Select the data or tool and drag it into the model.
- Alternatively, drag data and tools from search results in the Search window. See A quick tour of finding tools to learn about finding and adding tools using the Search window.
Connecting data and tools
There are two ways to connect variables to tool parameters: using the Connect tool or the tool's dialog box.
Using the Connect tool
- Click the Connect tool on the ModelBuilder toolbar.
- Click the variable you want to connect to a tool.
- Click the tool to which you want to connect the variable.
- From the pop up window of available parameters select the parameter you want to connect to.
A connection is made between the variable and the tool.
Using the tool dialog box
To use the tool's dialog box, right-click the tool and click Open.
- Alternatively, double-click the tool to open its dialog box.
For data on disk, browse to the data stored on disk, select it, and add the data.
- If the data has already been added to the model as a data variable, or if the data exists as a layer in the ArcMap table of contents, choose the appropriate data element from the parameter drop-down list. Data variables are shown with the Model Variable icon , and layers from the ArcMap table of contents are shown with the Layer icon .
Typically, tool parameters will accept variables from the model. In some cases, however, the parameter will not provide a list where variables can be selected. In these cases, create a new variable of the appropriate type in the model and use the Connect tool to connect the variable to the tool parameter.
You can connect a data element (or any variable) to any number of tools.