In This Article

BarComboBoxAutomationPeer Class

Exposes BarComboBox types to UI Automation.

public class BarComboBoxAutomationPeer : BarGalleryBaseAutomationPeer
Inheritance:
object AutomationPeer UIElementAutomationPeer FrameworkElementAutomationPeer ItemsControlAutomationPeer SelectorAutomationPeer BarGalleryBaseAutomationPeer object

Constructors

BarComboBoxAutomationPeer(BarComboBox)

Initializes a new instance of the BarComboBoxAutomationPeer class.

public BarComboBoxAutomationPeer(BarComboBox owner)
Parameter Type Description
owner BarComboBox

The owner element.

Properties

IsReadOnly

Gets a value that specifies whether the value of a control is read-only.

public bool IsReadOnly { get; }

Property Value

bool:

true if the value is read-only; false if it can be modified.

Value

Gets the value of the control.

public string Value { get; }

Property Value

string:

The value of the control as a string.

Methods

GetChildrenCore()

Gets the collection of child elements of the ItemsControl that is associated with this ItemsControlAutomationPeer. This method is called by GetChildren().

protected override List<AutomationPeer> GetChildrenCore()

Returns

List<AutomationPeer>:

The collection of child elements.

GetLocalizedControlTypeCore()

When overridden in a derived class, is called by GetLocalizedControlType().

protected override string GetLocalizedControlTypeCore()

Returns

string:

The type of the control.

GetPattern(PatternInterface)

Gets the control pattern for the Selector that is associated with this SelectorAutomationPeer.

public override object GetPattern(PatternInterface patternInterface)
Parameter Type Description
patternInterface PatternInterface

A value in the enumeration.

Returns

object:

If patternInterface is Selection, this method returns a pointer to the current instance; otherwise null.

SetValue(string)

Sets the value of a control.

public void SetValue(string value)
Parameter Type Description
value string

The value to set. The provider is responsible for converting the value to the appropriate data type.

Exceptions

Type Condition
InvalidOperationException

If locale-specific information is passed to a control in an incorrect format such as an incorrectly formatted date.

ArgumentException

If a new value cannot be converted from a string to a format the control recognizes.

ElementNotEnabledException

When an attempt is made to manipulate a control that is not enabled.

Inherited Members