On a windows 10 machine, I am seeing some problem where AutomationElement.FindFirst or AutomationElement.FindAll will generate the error "Element Not Available". (This never occurs in Windows 7)
On some windows 10 machines everything works find. On some other machine hosted in a different location nothing works because of this error.
After a lot of investigation I can say the machines are identical in what is installed. Only difference is where they are hosted (Performance is probably different)
The InnerException for these error is : {"Operation timed out. (Exception from HRESULT: 0x80131505)"}
So obviously it times out at searching the control.
The problem is that it times out right away, probably a fraction of a seconds.
Let say I have a toolbar with 40 buttons. If I use findfirst using AutomationID, the first 30 button will be found without problem, then starting at 31 it sometimes works and sometime not. Then button 40 never works. So it is timing out but way to quickly, pretty much instantly.
So the Question is: Where is the timeout forFindFirst & FindAll defined and how do I increase it to something more than a fraction of a second?