microsoft-ui-automation – UI Automation – 基于多个标识符选
发布时间:2020-12-14 02:07:42 所属栏目:Windows 来源:网络整理
导读:我是新来的.我正在使用UI Automation来自动化我的应用程序.有没有办法根据多个标识符识别元素. 目前以下语法仅能够基于一个标识符进行识别. AutomationElement okbtn = dialogbox.FindFirst(TreeScope.Children,new PropertyCondition(AutomationElement.Nam
我是新来的.我正在使用UI Automation来自动化我的应用程序.有没有办法根据多个标识符识别元素.
目前以下语法仅能够基于一个标识符进行识别. AutomationElement okbtn = dialogbox.FindFirst(TreeScope.Children,new PropertyCondition(AutomationElement.NameProperty,"OK")); 我想通过NameProperty和ControlTypeProperty获取标识元素. 这可能吗? 解决方法Condition cMenuItem = new AndCondition( new PropertyCondition(AutomationElement.LocalizedControlTypeProperty,"text"),"Appointment")); AutomationElement aeMenuItem = aeTaskMenu.FindFirst(TreeScope.Descendants,cMenuItem); (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
相关内容
- SMBv2和Windows 7
- Aspell 0.6 for Windows
- [问八系列] Windows 8 开发 (4): 分离检视型应用程序 Part
- windows-8 – 是否可以在Javascript Metro应用程序中使用C#
- Windows – PXE启动无法通过DHCP获取IP地址,但DHCP在操作系
- windows-server-2008 – 如何将现有的Windows Server 2008
- Win10操作系统无法访问局域网共享文件夹的问题
- 如何远程控制Windows?
- windows sc 添加创建exe服务;
- windows – cygwin curl,Wget,wget和top“命令未找到”
推荐文章
站长推荐
热点阅读