Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic How to get position of node? (Read 5430 times)
kim
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 3
Joined: Jul 11th, 2013
How to get position of node?
Jul 11th, 2013 at 7:37am
Print Post  
Hello, there.
I'm trying to create a tree graph using FlowChartX.
I want to have one function about node rearrangement.
To be specific, after I randomly move each node by drag & drop, I want rearrange them according to their position (i.e. Y-axis)
How can I get the position of each node?
Or do you have any idea for my work?
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: How to get position of node?
Reply #1 - Jul 11th, 2013 at 10:01am
Print Post  
Hi,

After moving nodes, you can run TreeLayout with its PreserveOrder property set to true to sort the arranged nodes by their initial positions.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
kim
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 3
Joined: Jul 11th, 2013
Re: How to get position of node?
Reply #2 - Jul 12th, 2013 at 12:11am
Print Post  
Firstly, thank you for your reply.
However, What I want to do is rearranging node by their current positions NOT initial position. Can you help me?
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: How to get position of node?
Reply #3 - Jul 12th, 2013 at 7:08am
Print Post  
I meant initial positions for the layout object at the time you run it, which are the current ones. E.g. this ObjectModified handler lets you rearrange nodes in a tree layer:

Code
Select All
Private Sub fcx_ObjectModified(ByVal obj As Object, ByVal selHandle As Long)
    Dim layout As New TreeLayout
    layout.Direction = tldLeftToRight
    layout.PreserveOrder = True
    fcx.ArrangeDiagram layout
End Sub 



I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
kim
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 3
Joined: Jul 11th, 2013
Re: How to get position of node?
Reply #4 - Jul 12th, 2013 at 8:36am
Print Post  
OK, I got it. I really thank you for your help.  Wink

B.R. H.Kim
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint