Hey Guys,
I'm currently facing the following problem:
I have a TreeControl with ~20 TreeItems inside, when I track it via the Spy everything is displayed correctly:
But when I'm trying to acces those TreeItems in code, it seems that some properties of the TreeItem objects are not set properly:
Since the neither the text nor the location properties are set, I'm having a hard time clicking the TreeItem, any advice?
Thanks in Advance, Phil
Tree.Items Properties not set
Tree.Items Properties not set
You do not have the required permissions to view the files attached to this post.
Re: Tree.Items Properties not set
Hi,
Unfortunately, without seeing the snapshot (NOT screenshot) of the tree and the code you are using, it's impossible to say what's wrong? My guess is, that you are accessing the tree incorrectly in code? Does your code looks like this?
Unfortunately, without seeing the snapshot (NOT screenshot) of the tree and the code you are using, it's impossible to say what's wrong? My guess is, that you are accessing the tree incorrectly in code? Does your code looks like this?
Code: Select all
public void ProcessTree(RepoItemInfo treeItemsInfo) // where treeItemsInfo points to repo element, with xpath pointing to list of tree items
{
IList <Ranorex.TreeItem> treeItemsList = treeItemsInfo.CreateAdapter<Ranorex.TreeItem>(false);
foreach (Ranorex.TreeItem treeItemSingle in treeItemsList )
{
string treeItemText = treeItemSingle.Element.GetAttributeValueText("Text");
}
}
Pavel Kudrys
Ranorex explorer at Descartes Systems
Please add these details to your questions:
Ranorex explorer at Descartes Systems
Please add these details to your questions:
- Ranorex Snapshot. Learn how to create one >here<
- Ranorex xPath of problematic element(s)
- Ranorex version
- OS version
- HW configuration