* tree3f.prg define class BinaryTree as custom moLeftChild = .null. moRightChild = .null. muData = .null. Name = "BinaryTree" protected procedure Init( puData ) this.muData = puData endproc procedure Insert( puData ) if ( puData < this.muData ) if ( IsNull( this.moLeftChild ) ) this.moLeftChild = createobject( "BinaryTree", puData ) else this.moLeftChild.Insert( puData ) endif else if( IsNull( this.moRightChild ) ) this.moRightChild = createobject( "BinaryTree", puData ) else this.moRightChild.Insert( puData ) endif endif endproc procedure InorderTraverse() if ( ! IsNull( this.moLeftChild ) ) this.moLeftChild.InorderTraverse() endif ?? this.muData, " " if ( ! IsNull( this.moRightChild ) ) this.moRightChild.InorderTraverse() endif endproc procedure Destroy() * postorder traverse to clean up tree this.moLeftChild = .null. this.moRightChild = .null. this.muData = .null. endproc enddefine>Im wondering how one would implement a set of records that are sorted tree like, as oposed to linearly. ie create a family tree where each node can have a marrage link, more than one children link, and a parent link. Not a simple tree, either: there would actualy have to be more that one marrage link, and maried into the family people would only have one link.