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. Image for the cookie policy date

Number of Ports

I made a symbol of my own as symbol palette Item and I added just three ports to that node one input and two output then i dragged that item to the DiagrammView and went to check on the number of the ports and it was 6 instead of 3 so how can I keep JUST my three ports


5 Replies

PA Parthiban A Syncfusion Team January 17, 2014 12:29 PM UTC

Hi Abdallah,

We have analysed your query regarding ports count getting increased while drag and drop from symbol palette. We could found that from our side. Internally we modify ports collection while serilizing and deserializing process. Finally we will maintain the ports collection as same. We suspect that you have checked ports count before that process ends. Could you please check with node loaded event, there you can get same no of ports in it. We checked that too.

Regards,

Parthiban A.

 



AR Abdallah Rabah January 21, 2014 10:57 AM UTC

Hi Parthiban,

Thank you for answering my post , I followed the steps you described and it did work expected
thanks

best regards
Abdallah


PA Parthiban A Syncfusion Team January 22, 2014 05:09 AM UTC

Hi Abdallah,
Thanks for your reply. Kindly let us know, if you require any further assist on this.
Regards,
Parthiban A.


AR Abdallah Rabah January 22, 2014 09:22 AM UTC

hi Parthiban

I am facing an other problem , is there any way to determine if a port is already connecte or not ? becouse I am trying to destrict the connection from output ports  so that every one can be used just once as Headport

best regards

abdallah rabah



PA Parthiban A Syncfusion Team January 28, 2014 12:12 PM UTC

Hi Abdallah,

We don’t have property to check whether port is connected. But we have to write own logic to check status of port. We have created a sample in which, we created CustomPort having property named “IsConnected”. The IsConnected property is being updated in ConnectorDragEnd event. Connector drag end event will be fired whenever the connector ends are dragged. By checking the IsConnected property we can allow connector to connect that port. Hence we can restrict the connection port to be connected to single line at a time.  For more information kindly refer the attached sample.

You can also refer our dash board sample InPortOutPort Demo,

WPF à Diagram à Editable Diagram àInPortOutPortDemo

Regards,

Parthiban A.



PortRestriction_8add0bc7.zip

Loader.
Up arrow icon