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
Trying to click through UltraTree nodes
It has been mentioned that UltraTree().click(atPath(path)) should work to "navigate" through the tree.

But, it's not. I'm getting various errors.

When the path is "Node1Level1->Node1Level2->Node3Level3", for example. If Node1Level1 isn't expanded, SubitemNotFoundException is thrown. If Node1Level1 is expanded, and I try UltraTree().setState(EXPAND, atPath("Node1Level1")), UnableToPerformActionException is thrown.

There is no "getState" for UltraTree() that I can find, to see if the node is expanded or not.

I have tried:
String[] arPath = Path.split("->");
String finalPath = "";
for (int i = 0; i " + arPath[j];
		finalPath = arPath[0];
	if (i == (arPath.length-1))
		UltraTree().click(atPath(finalPath + "->Location(CAPTION)"));
		UltraTree().setState(EXPAND, atPath(finalPath));
to click my way through the tree. But as I said, I get those exception thrown.

Not all nodes are expandable, as they don't have children.

Anyone has a better idea?

PS When I try to "ShowTree" from another thread, I got: [code] public void testMain(Object[] args) { UltraTreeTestObject myTree = ; // Variables to hold tree data ITestDataTree CdTree = (ITestDataTree) myTree.getTestData("all tree data"); ITestDataTreeNodes CdTreeNodes = CdTree.getTreeNodes(); ITestDataTreeNode[] CdTreeNode = CdTreeNodes.getRootNodes(); // Print out total number of nodes logInfo("Tree Total Node Count: " + CdTreeNodes.getNodeCount()); logInfo("Tree Root Node Count : " + CdTreeNodes.getRootNodeCount()); // loop through the tree root bands for (int i = 0; i