Table of Contents

Class SapElement

Namespace
Ranorex
Assembly
Ranorex.Plugin.Sap.dll

The element is a part of an SAP GUI application.

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

Constructors

SapElement()

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

protected SapElement()

SapElement(Element)

Creates a new SapElement adapter instance.

public SapElement(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

Changeable

Determines whether the component has user-changeable content.

public virtual bool Changeable { get; }

Property Value

bool

IconName

The name of the icon for this component, if available.

public virtual string IconName { get; }

Property Value

string

Modified

Determines whether the component has unsaved content.

public virtual bool Modified { get; }

Property Value

bool

Name

The name of the SAP component.

public virtual string Name { get; }

Property Value

string

RequiredCapabilities

Capabilities required by the adapter implementation.

protected override string[] RequiredCapabilities { get; }

Property Value

string[]

Text

The text associated with this component.

public virtual string Text { get; }

Property Value

string

Tooltip

The tooltip text associated with this component.

public virtual string Tooltip { get; }

Property Value

string

Type

The internal type of the SAP component.

public virtual string Type { get; }

Property Value

string

Methods

FromElement(Element)

Converts an Element to an instance of this class.

public static SapElement FromElement(Element element)

Parameters

element Element

The element to convert.

Returns

SapElement

The SapElement.

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 SapElement FromPath(string path)

Parameters

path string

The search path.

Returns

SapElement

The SapElement.

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.

ShowContextMenu()

Opens the context menu associated with the component, if available.

public virtual void ShowContextMenu()

Exceptions

ActionFailedException

Thrown if invoking the action failed.

Operators

implicit operator SapElement(Element)

Implicitly converts an Element to an instance of this class.

public static implicit operator SapElement(Element element)

Parameters

element Element

The element to convert.

Returns

SapElement

The SapElement.

Exceptions

ArgumentNullException

If element is null.

CapabilityNotSupportedException

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

implicit operator SapElement(string)

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

public static implicit operator SapElement(string path)

Parameters

path string

The search path.

Returns

SapElement

The SapElement.

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.