Schematic diagram auto refresh


Purpose
This sample is an ArcMap add-in that shows how to create a custom button that turns the automatic refresh feature on and off in a schematic diagram.

How to use

See How to use ArcGIS samples for help on compiling, setting up the debugger, and running the sample. If the sample has associated data, you will find that the sample's zip file includes a "data" folder alongside the language folders. However, you will need to update the sample to point to the location of the data once you have extracted all the files.

Building the component
  1. Open the solution file and build the project.

Configuring schematic attributes to be evaluated at On Start Editing
  1. Start ArcCatalog and edit a schematic dataset with a diagram template configured to work from a geometric network.
  2. Check the On Start Editing evaluation mode for any Associated Field schematic attribute that is used to label or symbolize the schematic features in the schematic diagrams.
  3. Save the schematic dataset and exit the Schematic Dataset Editor.

Adding the custom AutoRefresh button to the Schematic Editor toolbar
  1. Start ArcMap with a new empty map.
  2. Click Customize and click Customize Mode.
  3. Click the Commands tab and click AutoRefresh (VBNet) or AutoRefresh (C#) in the Categories list.
  4. Drag and drop the AutoRefresh command onto the Schematic Editor toolbar.

Testing auto refresh in the schematic diagram
  1. In the Layers data frame, add the geometric network data with which your diagram template works.
  2. Open a schematic diagram containing schematic features that were affected by the changes made during the On Start Editing evaluation, or generate a schematic diagram.
  3. Click Schematic Editor and click Start Editing Diagram on the Schematic Editor toolbar.
  4. Click the AutoRefresh (VBNet) or AutoRefresh (C#) button. The Schematic Auto Refresh Properties dialog box opens.
  5. Check the Auto Refresh On option, configure the time interval parameter values, then close the dialog box.
  6. In the active schematic diagram, select a schematic feature impacted by the changes made during the On Start Editing evaluation.
  7. Click Propagate Schematic Selection To Map on the Schematic toolbar. The associated feature is automatically selected in the Layers data frame.
  8. Activate this data frame and zoom in on the selected geographic information system (GIS) feature.
  9. On the Editor toolbar, click Editor and click Start Editing.
  10. Change some attribute values for the selected GIS feature.
  11. Activate the data frame containing the schematic diagram. After the specified time interval, all schematic attributes configured during the On Start Editing evaluation have been automatically re-evaluated. They reflect the changes you made to the associated GIS feature attributes. If these schematic attributes are used to label or symbolize the schematic feature, the impact is visual; the symbol or the label has been automatically changed.

Autorefresh.cs Implements the AutoRefresh button.
FormAutorefresh.cs Implements the form's interval time.
Download the C# files
Autorefresh.vb Implements the AutoRefresh button.
FormAutorefresh.vb Implements the form's interval time.
Download the VB.NET files

Download the files for all languages




Development licensing Deployment licensing
ArcGIS for Desktop Basic: Schematics ArcGIS for Desktop Basic: Schematics
ArcGIS for Desktop Standard: Schematics ArcGIS for Desktop Standard: Schematics
ArcGIS for Desktop Advanced: Schematics ArcGIS for Desktop Advanced: Schematics