This project is read-only.

Problem select treeNode if not completly visible

Jul 10, 2009 at 5:52 PM



I have TreeNode with a long name. Problem if I try to select this item in real an element in the pane right from the tree is selected.

The problem is that the click action will be perfomrmed on the center of the item, and the center is hidden by the next pane.

Maybe it will be better to search the clickable point on the center of the visible part, and if the node is completly hidden (left to right) we should scroll right first..


Is there a workaround for this problem?


Jul 11, 2009 at 9:45 AM

you can click at any point using the mouse object.

Mouse.Instance.Click(point, window);

Jul 11, 2009 at 9:56 AM

yes I have found it to, I get the cliackable point over the AutomationElement, and than I use DoubleClick.



Jul 14, 2009 at 1:05 PM

can you please ive an example i have about similar problem not able to click a button that is not visible in the list.

Jul 14, 2009 at 2:22 PM
Edited Jul 14, 2009 at 2:23 PM


I get the node (TreeNode) (TreeNode node = tree.GetElement(<Path to the node>);)

Point i = node.AutomationElement.GetClickablePoint();

window.Mouse.DoubleClick(new Point((int)i.X), (int)i.Y )); //window is the window which contains the node

Note: the treeNode is partial visible. DoubleClick because I want that the node expanded