[IronPython] UI Automation and ControlTypeProperty
Marcel
marcel.vandendungen at gmail.com
Sat Mar 22 16:33:48 CET 2008
Hi,
I was reading the article on UI automation in MSDN (http://
msdn2.microsoft.com/en-us/magazine/cc163288.aspx) and decided to use
IronPython to control the example.
Unfortunately, I found that finding elements based on type doesn't
work. The example application has 1 button on the form. If I type the
following code I get an AutomationElement object:
form.FindFirst(TreeScope.Children,
PropertyCondition(AutomationElement.NameProperty, "Calculate"))
But with the following code, I get None returned:
form.FindFirst(TreeScope.Children,
PropertyCondition(AutomationElement.ControlTypeProperty,
ControlType.Button))
The C# code that accompanies the article successfully uses the FindAll
with AutomationElement.ControlTypeProperty. Is this a known issue in
IronPython? I'm using IronPython 1.1.1. Is this fixed in 2.0?
TIA,
-- Marcel
More information about the Ironpython-users
mailing list