Skip to content

Bind positions of diagram items to source properties in two-way mode.

License

Notifications You must be signed in to change notification settings

DevExpress-Examples/wpf-diagram-bind-item-positions-to-source-objects

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

WPF Diagram Control - Bind Item Positions to Source Objects

This example demonstrates how to bind positions of diagram items to source properties (in two-way mode) when you generate these items from a source collection.

image

Create a DiagramBinding object, specify target and source properties and binding mode, and assign the object to the DiagramItem.Bindings property:

<dxdiag:DiagramShape.Bindings>
    <dxdiag:DiagramBinding PropertyName="Position"
                           Expression="Position"
                           Mode="TwoWay"/>
</dxdiag:DiagramShape.Bindings>

Handle the DiagramDataBindingBehaviorBase.CustomLayoutItems event to disable the default layout algorithm.

Files to Review

Documentation

More Examples

Does this example address your development requirements/objectives?

(you will be redirected to DevExpress.com to submit your response)

About

Bind positions of diagram items to source properties in two-way mode.

Topics

Resources

License

Stars

Watchers

Forks