Redigera

Dela via


ControlType Class

Definition

Identifies the type of a user interface (UI) control.

public ref class ControlType : System::Windows::Automation::AutomationIdentifier
public class ControlType : System.Windows.Automation.AutomationIdentifier
type ControlType = class
    inherit AutomationIdentifier
Public Class ControlType
Inherits AutomationIdentifier
Inheritance

Remarks

ControlType inherits from AutomationIdentifier and is used to identify the type of a control represented by an AutomationElement. The control type is determined by the developer of the UI Automation provider.

This class contains static fields, which are themselves ControlType objects, to identify the standard types of controls. There is also a Custom type for controls that do not match one of the defined types.

The only case where a control's control type might change at run time is where the control supports MultipleViewPattern. An example is the Win32 list view, which can be a DataGrid or List, depending on the current view.

Control types do not have a one-to-one equivalence to control patterns. A control can be of only one type, but it may support multiple patterns or no patterns at all, depending on its specific functionality.

For detailed information on the various control types, see UI Automation Control Types.

Fields

Button

Identifies a button control.

Calendar

Identifies a calendar control, such as a date-picker.

CheckBox

Identifies a check box control.

ComboBox

Identifies a combo box control.

Custom

Identifies a control that is not one of the defined control types.

DataGrid

Identifies a data grid control.

DataItem

Identifies a data item control.

Document

Identifies a document control.

Edit

Identifies an edit control, such as a text box.

Group

Identifies a group control, which acts as a container for other controls.

Header

Identifies a header control, which is a container for the labels of rows and columns of information.

HeaderItem

Identifies a header item, which is the label for a row or column of information.

Hyperlink

Identifies a hyperlink control.

Image

Identifies an image control.

List

Identifies a list control, such as a list box.

ListItem

Identifies a list item control, which is a child item of a list control.

Menu

Identifies a menu control, such as a top-level menu in an application window.

MenuBar

Identifies a menu bar control, which generally contains a set of top-level menus.

MenuItem

Identifies a menu item control.

Pane

Identifies a pane control.

ProgressBar

Identifies a progress bar control, which visually indicates the progress of a lengthy operation.

RadioButton

Identifies a radio button control, which is a selection mechanism allowing exactly one selected item in a group.

ScrollBar

Identifies a scroll bar control, such as a scroll bar in an application window.

Separator

Identifies a separator, which creates a visual division in controls like menus and toolbars.

Slider

Identifies a slider control.

Spinner

Identifies a spinner control.

SplitButton

Identifies a split button, which is a button that performs a default action and can also expand to a list of other possible actions.

StatusBar

Identifies a status bar control.

Tab

Identifies a tab control.

TabItem

Identifies a tab item control, which represents a page of a tab control.

Table

Identifies a table.

Text

Identifies an edit control, such as a text box or rich text box.

Thumb

Identifies the control in a scrollbar that can be dragged to a different position.

TitleBar

Identifies the caption bar on a window.

ToolBar

Identifies a toolbar, such as the control that contains a set of command buttons in an application window.

ToolTip

Identifies a tooltip control, an informational window that appears as a result of moving the pointer over a control or sometimes when tabbing to a control using the keyboard.

Tree

Identifies a tree control.

TreeItem

Identifies a node in a TreeItem control.

Window

Identifies a window frame, which contains child objects.

Properties

Id

Gets the underlying numerical identifier.

(Inherited from AutomationIdentifier)
LocalizedControlType

Gets a description of the control type.

ProgrammaticName

Gets the registered programmatic name.

(Inherited from AutomationIdentifier)

Methods

CompareTo(Object)

Compares this AutomationIdentifier with another AutomationIdentifier.

(Inherited from AutomationIdentifier)
Equals(Object)

Returns a value indicating whether the supplied AutomationIdentifier is equivalent to this AutomationIdentifier.

(Inherited from AutomationIdentifier)
GetHashCode()

Returns the hash code for this UI Automation identifier.

(Inherited from AutomationIdentifier)
GetNeverSupportedPatterns()

Retrieves the pattern identifiers that are not supported by the control type.

GetRequiredPatternSets()

Retrieves an array of sets of required patterns.

GetRequiredProperties()

Retrieves an array of the required property identifiers (IDs) for this control type.

GetType()

Gets the Type of the current instance.

(Inherited from Object)
LookupById(Int32)

Retrieves a ControlType that encapsulates a specified numerical identifier.

MemberwiseClone()

Creates a shallow copy of the current Object.

(Inherited from Object)
ToString()

Returns a string that represents the current object.

(Inherited from Object)

Applies to

See also