Hy,
I've got the following Problem.
If i Save the Diagram to String and Load the string back into the same Diagram, my binding doesn't work anymore.
Bug inside the Diagram Framework or OSI Layer 9 (20 cm in the front of the monitor) ?
XAML:
Code Behinde
Method who call the Reload and Load
Greetings
Alfred
I've got the following Problem.
If i Save the Diagram to String and Load the string back into the same Diagram, my binding doesn't work anymore.
Bug inside the Diagram Framework or OSI Layer 9 (20 cm in the front of the monitor) ?
XAML:
<telerik:RadDiagramShape x:Class="SPARE_BPMS_Framework.Shapes.General.ProcessShape" mc:Ignorable="d" Content="{Binding}" xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" d:DesignHeight="300" d:DesignWidth="300"> <telerik:RadDiagramShape.Resources> <DataTemplate x:Key="editTemplate"> <StackPanel Orientation="Horizontal"> <TextBox Height="24" Text="{Binding Name}" /> </StackPanel> </DataTemplate> <DataTemplate x:Key="template"> <WrapPanel Orientation="Vertical"> <TextBlock Text="{Binding Name}" /> <TextBlock Text="{Binding ChildProcessName}" /> </WrapPanel> </DataTemplate> </telerik:RadDiagramShape.Resources></telerik:RadDiagramShape>Code Behinde
public partial class ProcessShape : RadDiagramShape { public ProcessItem Model { get; set; } public string Name { get; set; } public ProcessShape() { InitializeComponent(); Model = new ProcessItem(); this.EditTemplate = (DataTemplate)this.FindResource("editTemplate"); this.ContentTemplate = (DataTemplate)this.FindResource("template"); this.DataContext = Model; this.MouseDoubleClick += new MouseButtonEventHandler(Model.shape_MouseDoubleClick); } public void Update() { this.EditTemplate = (DataTemplate)this.FindResource("editTemplate"); this.ContentTemplate = (DataTemplate)this.FindResource("template"); } }Method who call the Reload and Load
string temp = diagram.Save(); diagram.Clear(); diagram.Load(temp);Greetings
Alfred