How to use
See How to use ArcGIS samples for help on compiling, setting up the debugger, and running the sample.
Data has been provided for your use with this sample. It can be found at
<Your ArcGIS Developer Kit Install directory>/Samples/data/Schematics/GISForXMLSample.
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
- Start Visual Studio, open the solution file, and build the component.
Copying the sample database in a working folder
- Navigate to <ArcGIS DeveloperKit install location>\Samples\data\Schematics
- Copy both the GISForXMLSample.gdb geodatabase and the GISForXMLSample.mxd file in a folder for which you have full rights.
Configuring the schematic dataset
- Start ArcCatalog.
- Browse to the GISForXMLSample geodatabase you have just copied.
- Right-click the GISForXMLSample_Schematic schematic dataset contained in this geodatabase and click Edit. The Schematic Dataset Editor opens.
- Click the XMLDiagrams diagram template in the Dataset Editor tree.
- On the Properties tab on the right, click the Schematic Builder Properties button. The Schematic Builder Properties dialog box opens.
- Type MyExtXMLComponentCS.XMLDocImpl or MyExtXMLComponentVB.XMLDocImpl (depending on the language you're using) in the Generate and Update fields.
- Check the Initialize link vertices and Automatic schematic feature class creation options.
- Click OK.
- Click Save and exit the Schematic Dataset Editor.
Testing the XML builder diagram generate and update functions
- Start ArcMap and open the GISForXMLSample.mxd file from your working folder. This .mxd file references the ElectricDataset feature dataset stored in the copied GISForXMLSample geodatabase.
- Start the Schematics extension.
- In ArcMap, click Customize, click Toolbars, and choose the Schematic, Schematic Editor, and Schematic Network Analyst toolbars.
- Click the Select Features tool on the Tools toolbar and select a set of features on the active data frame.
- Click Generate New Schematic Diagram on the Schematic toolbar. The New Schematic Diagram dialog box opens.
- Ensure that the GISForXMLSample_Schematic schematic dataset is selected on the Schematic Dataset or Schematic Folder drop-down list and that the XMLDiagrams diagram template is selected on the Schematic Diagram Template drop-down list.
- Type a name for the diagram in the Schematic Diagram Name field, for example, XMLDiagramFromSelection1.
- Click OK. The XMLDiagramFromSelection1 diagram, based on the selected set of features, is generated and opens in a new data frame.
- Activate the Layers data frame containing the ElectricDataset features and select a new set of features.
- Click Schematic on the Schematic toolbar and click Update Diagram. The Update Diagram dialog box opens.
- Click OK. The active diagram is updated according to the features currently selected on the map.
- Select the Propagate Map Selection to Schematic command to confirm that the schematic features contained in the active diagram are correctly associated with the features from which they were created.
XMLDocImpl.vb | Implementation of the ISchematicXMLGenerate and ISchematicXMLUpdate interfaces. |
XMLDocImpl.cs | Implementation of the ISchematicXMLGenerate and ISchematicXMLUpdate interfaces. |
Download the files for all languages
See Also:
ISchematicXMLGenerate interfaceISchematicXMLUpdate interface
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 |