Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic DiagramLink (Read 1978 times)
Tima
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 25
Joined: Nov 10th, 2010
DiagramLink
Jul 25th, 2011 at 8:54am
Print Post  
I need to Create Link between two Nodes but Start from Right Side of Node and End Point of link into the Left Side of another Node.

What should i used for this
Thanks.
  
Back to top
 
IP Logged
 
Meppy
God Member
*****
Offline


MindFusion support

Posts: 1783
Joined: Jul 20th, 2005
Re: DiagramLink
Reply #1 - Jul 25th, 2011 at 10:45am
Print Post  
You can either use appropriate anchor patterns for both nodes or manually adjust the points of the newly created link so that it starts from the right side of the origin node and ends to the left side of the destination node. Here is a sample code illustrating how to do this:

Code
Select All
link.ControlPoints.Clear();
link.ControlPoints.Add(new Point(node1.Bounds.Right, node1.Bounds.Top + node1.Bounds.Height / 2));
link.ControlPoints.Add(new Point(node2.Bounds.Left, node2.Bounds.Top + node2.Bounds.Height / 2));
link.UpdateFromPoints(); 


I hope this helps.

Regards,
Meppy
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint