Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Find tablenode using ID (Read 1590 times)
newbieDraw
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 24
Joined: Dec 22nd, 2011
Find tablenode using ID
Feb 15th, 2012 at 10:29am
Print Post  
Hello,

I am developing an app to design bayesian networks using tablenodes. Each table node holds 2 values in 2 rows. Is there a method I can use to access the table node (like FindNodebyID method). I need to access all the table nodes in the diagram so I can analyze the network structure. What is a suggested way to accomplish this?

Thanks,

  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Find tablenode using ID
Reply #1 - Feb 15th, 2012 at 12:03pm
Print Post  
This will loop over all tables:

Code
Select All
foreach (DiagramNode node in diagram.Nodes)
{
      TableNode table = node as TableNode;
      if (table == null)
            continue;
      // process table
} 



Or if you need to access specific table by id, you will have to cast the FindNodeById result:
TableNode table = (TableNode)diagram.FindNodeById(...);

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


I love YaBB 1G - SP1!

Posts: 24
Joined: Dec 22nd, 2011
Re: Find tablenode using ID
Reply #2 - Feb 16th, 2012 at 6:31am
Print Post  
Thanks, Stoyo. I have another query regarding the same project that I have posted as a separate thread. Please have a look at that too.
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint