Table of Contents

Class UIAutomationInvoke

Namespace
Ranorex
Assembly
Ranorex.Plugin.Uia.dll

Capability for the UIA Invoke pattern.

public class UIAutomationInvoke : Adapter, IAdapter
Inheritance
UIAutomationInvoke
Implements
Inherited Members

Constructors

UIAutomationInvoke()

Creates a new UIAutomationInvoke adapter instance. This constructor is used internally by the Ranorex Core Framework for performance issues!

protected UIAutomationInvoke()

UIAutomationInvoke(Element)

Creates a new UIAutomationInvoke adapter instance.

public UIAutomationInvoke(Element element)

Parameters

element Element

The element to create the adapter for.

Exceptions

NullReferenceException

If element is null.

CapabilityNotSupportedException

If the element does not support the capabilities required by this adapter.

Properties

RequiredCapabilities

Capabilities required by the adapter implementation.

protected override string[] RequiredCapabilities { get; }

Property Value

string[]

Methods

FromElement(Element)

Converts an Element to an instance of this class.

public static UIAutomationInvoke FromElement(Element element)

Parameters

element Element

The element to convert.

Returns

UIAutomationInvoke

The UIAutomationInvoke.

Exceptions

ArgumentNullException

If element is null.

CapabilityNotSupportedException

If the element does not support the capabilities required by this adapter.

FromPath(string)

Converts a string to an instance of this class by searching the root.

public static UIAutomationInvoke FromPath(string path)

Parameters

path string

The search path.

Returns

UIAutomationInvoke

The UIAutomationInvoke.

Remarks

The DefaultSearchTimeout is used to search for the specified path.

Exceptions

ArgumentNullException

If path is null.

RxPathException

If the specified path is not valid.

ElementNotFoundException

If no element is found.

CapabilityNotSupportedException

If the element does not support the capabilities required by this adapter.

Invoke()

Sends a request to the element to initiate its action.

[OriginalDisplayName("UIAutomationInvokeInvoke")]
public virtual void Invoke()

Exceptions

ActionFailedException

Thrown if invoking the action failed.

Operators

implicit operator UIAutomationInvoke(Element)

Implicitly converts an Element to an instance of this class.

public static implicit operator UIAutomationInvoke(Element element)

Parameters

element Element

The element to convert.

Returns

UIAutomationInvoke

The UIAutomationInvoke.

Exceptions

ArgumentNullException

If element is null.

CapabilityNotSupportedException

If the element does not support the capabilities required by this adapter.

implicit operator UIAutomationInvoke(string)

Implicitly converts a string to an instance of this class by searching the root.

public static implicit operator UIAutomationInvoke(string path)

Parameters

path string

The search path.

Returns

UIAutomationInvoke

The UIAutomationInvoke.

Remarks

The DefaultSearchTimeout is used to search for the specified path.

Exceptions

ArgumentNullException

If path is null.

RxPathException

If the specified path is not valid.

ElementNotFoundException

If no element is found.

CapabilityNotSupportedException

If the element does not support the capabilities required by this adapter.