Custom Treeview for Data Framework

How can I iterate through the OCAF document main label and populate my application's treeview instead of using the DFBrowser?

Dirk B's picture

Hi Nair,
here's a little code for the task:

void Traverse( TDF_Label label, TreeView tv )
TreeItem ti = tv.AddTreeItem();
AddAttributesToTreeItem( label, ti );
for( TDF_ChildIterator it( L, Standard_False ); it.More(); it.Next() )
Traverse( it.Value(), tv );

Sharjith Naramparambath's picture


Thanks a lot. You have given me a good direction.

N. Sharjith