We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Saving of custom property values in .edd files.

Thread ID:

Created:

Updated:

Platform:

Replies:

88414 Jul 22,2009 11:09 AM UTC Jul 23,2009 09:04 AM UTC ASP.NET Web Forms (Classic) 1
loading
Tags: DiagramWebControl
Santanu Sarma
Asked On July 22, 2009 11:09 AM UTC

Hi,
I am using Syncfusion 7.2.0.20 Essential Diagram component. My requirement is to create a digram with my custom created symbol with custom properties that can be modified at runtime, save it to a ".edd" file (if possible) and retrieve it again. I am referring to the "Diagram Builder" sample.

To the "Diagram Builder" source code, I have added one extra Symbol palette with my custom created symbol where I have created a custom property. When I drag & drop the custom symbol onto the digram and select it, the property editor shows the custom property as per the requirement.

But the custom property value is not same as the modified value
when the custom property value is modified from the property editor, the digram saved to a ".edd" file and the diagram window closed and reopened.

Is there anyway to save the value of the custom property along with the ".edd" file and retrieve it later on?

I am attaching the source code for your reference.

Regards,
Santanu.




DiagramBulider_CustomSymbol_CustomProperties_7473450c.rar

Dinesh M [Syncfusion]
Replied On July 23, 2009 09:04 AM UTC

Hi Santanu,

In your sample i found that you haven't added the following code for serializing and deserializing the MyCustomProperty.

In MySymbol.cs file.

protected MySymbol(SerializationInfo info, StreamingContext context) : base(info, context)
{
this.myVar = info.GetInt32("strMyCustomProperty");
}

protected override void GetObjectData(SerializationInfo info, StreamingContext context)
{
base.GetObjectData(info, context);
info.AddValue("strMyCustomProperty", this.myVar);
}

The modified sample can be downloaded from the following location.

http://files.syncfusion.com/support/Diagram.Windows/Forums/DiagramBulider_CustomSymbol_CustomProperties.zip

Regards,
Dinesh


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;