Skip to main content
A newer version of this page is available. .

Data Binding

You can bind the ASPxDiagram control to the following data source types.

  • Node and Edge Data Sources: two separate lists store information about nodes (shapes) and edges (connectors).
  • Self-Referenced Data Source: a single list that stores nodes (shapes). If a node specifies a Parent Key value, it references another node and thus defines an edge (connector).

The following table lists the mappings you need to specify so that the control can load the diagram structure.

Required Properties Node and Edge Data Sources Self-Referenced Data Source
Mappings.Edge.Key yes no
Mappings.Node.Key yes yes
Mappings.Node.ParentKey no yes

Optional binding properties allow you to specify element content and appearance.

Handle the NodeDataBound and EdgeDataBound events to customize node or edge settings before it is rendered.