internal AutomationElementTreeNode FindChildNodeForAutomationElementInternal(AutomationElement element)
{
//go thru the childern collection and compare them
foreach (AutomationElementTreeNode childNode in new AutomationElementTreeNodeCollection(this))
{
if (childNode.AutomationElement == element)
return childNode; //yes! we found it
}
//currentTestTypeRootNode was not founded
return null;
}