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 : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Node Border color to change while trying to connect nodes

Thread ID:

Created:

Updated:

Platform:

Replies:

123220 Feb 26,2016 03:08 PM UTC Feb 29,2016 01:01 PM UTC WPF 1
loading
Tags: Diagram
ashish
Asked On February 26, 2016 03:08 PM UTC

Hi,

We have a requirement where we drag custom nodes on canvas say for example 4 custom node.
When we try to connect the two nodes we need to change the node border color of all the nodes which are available on canvas as per business logic.
But we didn't found any event other than mentioned below.

1) ConnectorDragStart 
2) ConnectorDragEnd
3) AfterConnectionCreate

All the above event gets fired when two nodes are connected.
Is there any event which will get raised as soon as we start to connect the two nodes.
For eg when we will try to connect head node with tail node as soon as connector line is being dragged then the border color of all the node has to be changed.

Thanks,
Ashish Nandavadekar

Ranjitha Amirthalingam [Syncfusion]
Replied On February 29, 2016 01:01 PM UTC

Hi Ashish,

Thanks for contacting Syncfusion Support.

Please find the response to your queries as below.


S.No
Query
Response
1
When we try to connect the two nodes we need to change the node border color of all the nodes which are available on canvas as per business logic.
But we didn't found any event other than mentioned below.

1) ConnectorDragStart 
2) ConnectorDragEnd
3) AfterConnectionCreate

All the above event gets fired when two nodes are connected.

We have support to change the border color of the Node using BorderBrush and Border Thickness properties of Node.We have provided code example to represent this.Please refer to the code example as below.

Code Example:

node.BorderBrush = new SolidColorBrush(Colors.Red);
node.BorderThickness = new Thickness(5);

//Here, node is the instance of Node.


2
Is there any event which will get raised as soon as we start to connect the two nodes.
For eg when we will try to connect head node with tail node as soon as connector line is being dragged then the border color of all the node has to be changed.

We don’t have support for “an event will get raised when two nodes starts to connect”. We have HeadNodeChanged and TailNodeChanged events, which will get raised when the HeadNode and TailNode of the Connector is changed.




Regards,
Ranjitha A.

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

;