The Utility Network Analyst toolbar has a set of trace tasks (Find Connected, Trace Upstream, etc.)
then can be used to solve many problems. The Next Upstream Device Task demonstrates how to create a custom
trace task to add to the existing set of functionality. The task is designed to find the next upstream device
from the specified flag based on the set of disabled layers. When performing the upstream trace,
only those layers that have been disabled in the toolbar will be used for finding the next upstream device.
As an example, if I want to find the next upstream valve from my flag, then I would disable only the valve
How to use:
Register the trace task with Categories.exe as an ESRI Utility Network Task.
Close and restart ArcMap.
Add your network to ArcMap. Use the Add Edge Flag or Add Junction Flag tools on the Utility Network
Analyst toolbar to place a flag at the location you wish to trace from.
Disable one or more layers using the toolbar (disable the layers whose features you want to
Choose "Next Upstream Device" from the list of available trace tasks and perform the trace.
The result will be a selection set up the upstream devices that stopped the trace.
An Arcmap session with a geometric network loaded.