It works when I first drag and drop from snapping stecil. But I can't Snapping between the items I uploaded to the diagram. What could be the reason? can you help?
<Syncfusion:Ruler Orientation="Vertical" />
We are unable to reproduce the reported issue that the snap-lines do not appear correctly when interacting with the nodes in the diagram. We have shared you a sample for your reference. Could you please check the sample and try to modify it to reproduce the issue?
Thank you for the answer. I will apply. As an additional question, when I do Ctrl+C Ctrl+V, the object is copied but the object is empty. Do I have to activate something for this?
In SfDiagram, we cannot directly serialize the Content and ContentTemplate properties of a Node. However, we can accomplish this using custom properties. Please refer to the attached modified sample, which enables copying and pasting an object with a custom template.
Hello, I solved all my problems, thank you. When the node is deleted in the demo you sent, I get a binding error as follows. What is the reason ?
System.Windows.Data Error: 23 : Cannot convert '<null>' from type '<null>' to type 'System.Windows.Media.ImageSource' for 'en-US' culture with default conversions; consider using Converter property of Binding. NotSupportedException:'System.NotSupportedException: ImageSourceConverter, (boş) öğesinden dönüştüremez.
path: System.ComponentModel.TypeConverter.GetConvertFromException(Object value)
path : System.Windows.Media.ImageSourceConverter.ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, Object value)
path : MS.Internal.Data.DefaultValueConverter.ConvertHelper(Object o, Type destinationType, DependencyObject targetElement, CultureInfo culture, Boolean isForward)'
We have identified the reported binding error is caused by clearing the Content property prior to the ContentTemplate property while disposing the node. We will resolve this internally in our upcoming release.
To prevent this error in the meantime, please use the code provided below:
(diagram.Info as IGraphInfo).ItemDeleted += (s, e) =>
if (e.Item is INode node) node.ContentTemplate = null;