Contributions
Obtaining UIAutomation properties from WPF objects
I am trying to script automated testing for a desktop WPF application. I had initially tried giving priority to NativeUIAObject as a way of accessing the application elements but I discovered great difficulty with trying to obtain field values in some cases. I then experimented with giving priority to NativeClrObject and for the most part this has worked much better. However, I miss being able to use some of the properties that were exposed with the UIAutomation approach. Is there any way to expose both? I have tried selecting "*" for my CurrentProjectOptions | Open Applications | UI Automation but this hasn't helped.649Views0likes1CommentRe: Obtaining AutomationId from WPF applications
In my case I am interested in the VerticallyScrollable property of a UIAutomation object for a WPF application. I tried modifying the sampleprovided in Tanya's postafter proving I could successfully obtain the AutomationID. However, I am sure I am making an obvious mistake: (Using JavaScript...) var SV, AutomationIdProperty, AutomationID; SV = Sys.Process("MyApp"); AutomationIdProperty = SV.AppDomain("MyApp.exe").dotNET.System_Windows_Automation.AutomationProperties.AutomationIdProperty; AutomationID = MyWPFObject.GetValue(AutomationIdProperty); Log.Message(AutomationID); //Success!! AutomationIdProperty = SV.AppDomain("Zetta.exe").dotNET.System_Windows_Automation.ScrollPattern.VerticallyScrollableProperty; AutomationID = MyWPFObject.GetValue(AutomationIdProperty); //Fails here with error: "The parameter is incorrect" Log.Message(AutomationID);1KViews0likes1Comment