| || |
How to check child node in the tree view
Using QTP in Java application, How to check whether the Child node exist or not under the parent node?
Plz help ....its very [stupid is as stupid does]...
Thx in advance
Re: How to check child node in the tree view
I don't know you specific java tree, so maybe there's a straighter way of doing this.
Usually tapping into the run-time object properties (by using QTPObject.Object.Property) is a good way of doing these things. In this case search for something like CurrentNode.Object.Children - it will usually be a collection which you can run through with a FOR loop, and check each child's text/title/whatever.
In some trees, you can start from CurrentNode, and you'll have to make your way through the root of the tree, up the entire node-path. This is why there maybe better way of doing this.
All the best.