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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Node.Name and Connector.Name cannot be int number

Thread ID:





126315 Oct 6,2016 09:15 PM UTC Oct 7,2016 07:31 AM UTC ASP.NET MVC 1
Tags: Diagram
Tom Frajer
Asked On October 6, 2016 09:15 PM UTC

I'm trying tu put database Id's into Name properties of Connector and Node in my diagram, but when I do this, diagram will not render. Reason why I want to do this is that it is easier for me to track changes in diagram and then save them into my database model. Good thing is, that when I change connector's SourceNode and/or TargedNode I will automatically have correct database id's of connected nodes in those properties. I do not want to use text names as they do not have to be unique (user can have two nodes with same name). Of course I can use textual unique identificator such as Guid for this, but I think it will be much easier and cleaner if I put database Id into Name properties of Connectors and Nodes.

What do you think? Any ideas?

Shyam G [Syncfusion]
Replied On October 7, 2016 07:31 AM UTC

Hi Tom, 

You can use models dataSourceSettings Id property and models dataSourceSettings connectionDataSource Id property which map the database column values into the node’s name and connectors name property respectively. Please refer to the code example and sample below. 

Code example: 

  model.DataSourceSettings = new DataSourceSettings() 
                DataSource = DiagramContext.NodeDetails.ToList(), 
                Id = "Name", 
                ConnectionDataSource = new ConnectionDataSourceSettings() 
                    DataSource = DiagramContext.ConnectorDetails.ToList(), 
                    Id = "Name", 

Shyam G 


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

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