Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
649
How to retrieve data from UltraTreeview?
posted

 HI,

How to retrieve data from UltraTreeview?

i tried the below code. It is not working 'due to 'Object reference not set to an instance' error.


           ' Declare variables for tree
        Dim CdTree As ITestDataTree
        Dim CdTreeNodes As ITestDataTreeNodes
        Dim CdTreeNode() As ITestDataTreeNode

        ' Variables to hold tree data
        CdTree = Tree2().GetTestData("TreeView")
        CdTreeNodes = CdTree.GetTreeNodes() - ----- "Error at this line 'Object reference not set to an instance of an object'"
        CdTreeNode = CdTreeNodes.GetRootNodes()

 

 

' Print out total number of nodes

 MsgBox("Tree Total Node Count: " + CdTreeNodes.GetNodeCount())

MsgBox(

"Tree Root Node Count : " + CdTreeNodes.GetRootNodeCount())

' Iterate through tree branches; this is a recursive method.

        Dim I As Integer

        For I = 0 To CdTreeNode.Length - 1
            ShowTree(CdTreeNode(I), 0)
        Next I

Thanks in advance.

 Rekha. 

 

Parents Reply Children
No Data