UITechnologyManager.GetFocusedElement 方法

定义

重载

GetFocusedElement(IntPtr)

返回当前具有焦点的元素的 windows 指针。

GetFocusedElement(AutomationElement)

GetFocusedElement(IntPtr)

返回当前具有焦点的元素的 windows 指针。

public:
 abstract Microsoft::VisualStudio::TestTools::UITest::Extension::IUITechnologyElement ^ GetFocusedElement(IntPtr handle);
public abstract Microsoft.VisualStudio.TestTools.UITest.Extension.IUITechnologyElement GetFocusedElement (IntPtr handle);
abstract member GetFocusedElement : nativeint -> Microsoft.VisualStudio.TestTools.UITest.Extension.IUITechnologyElement
Public MustOverride Function GetFocusedElement (handle As IntPtr) As IUITechnologyElement

参数

handle
IntPtr

nativeint

IntPtr具有焦点的窗口的。

返回

IUITechnologyElement

具有焦点的元素; 如果没有元素具有焦点,则为 null。

实现

适用于

GetFocusedElement(AutomationElement)

public:
 virtual Microsoft::VisualStudio::TestTools::UITest::Extension::IUITechnologyElement ^ GetFocusedElement(System::Windows::Automation::AutomationElement ^ ceilingElement);
public virtual Microsoft.VisualStudio.TestTools.UITest.Extension.IUITechnologyElement GetFocusedElement (System.Windows.Automation.AutomationElement ceilingElement);
abstract member GetFocusedElement : System.Windows.Automation.AutomationElement -> Microsoft.VisualStudio.TestTools.UITest.Extension.IUITechnologyElement
override this.GetFocusedElement : System.Windows.Automation.AutomationElement -> Microsoft.VisualStudio.TestTools.UITest.Extension.IUITechnologyElement
Public Overridable Function GetFocusedElement (ceilingElement As AutomationElement) As IUITechnologyElement

参数

ceilingElement
AutomationElement

返回

IUITechnologyElement

适用于