Interface IListBox
A drop-down or multiple-selection Web list.
HTML example with the second value selected:
<select name="select">
<option value="value1">Value 1</option>
<option value="value2" selected>Value 2</option>
<option value="value3>Value 3</option>
</select>
public interface IListBox : IWebElement, ITestObject, IClickable, IWebTestObject, IWebDescriber, ITestObjectDescriber, ILocationInfoProvider, ISupportsNativeObject, IVisibleProvider, ISupportDragAndDrop, IEnabledProvider
- Inherited Members
- Extension Methods
Properties
DefaultValue
The initial text value, which is set when the object is reset.
string DefaultValue { get; }
Property Value
IsMultiple
Indicates whether multi-selection is available.
bool IsMultiple { get; }
Property Value
Items
A collection of all IListItem objects in the list.
ReadOnlyCollection<IListItem> Items { get; }
Property Value
Remarks
When weblist items are loaded dynamically, it is possible that only a partial list of the items will be returned.
SelectedItems
A collection of all selected items in the list.
ReadOnlyCollection<IListItem> SelectedItems { get; }
Property Value
Type
The attribute "type" of the HTML element.
string Type { get; }
Property Value
Value
This object's text value.
string Value { get; }
Property Value
VisibleItemsCount
The number of visible items in the list.
uint VisibleItemsCount { get; }
Property Value
Methods
Deselect(params IListItem[])
Deselects a list of items in the list box.
void Deselect(params IListItem[] items)
Parameters
Deselect(params string[])
Deselects items from the list based on the item names.
void Deselect(params string[] items)
Parameters
itemsstring[]A collection of items to deselect.
Deselect(params uint[])
Deselects items from the list based on the item indices.
void Deselect(params uint[] itemIndices)
Parameters
itemIndicesuint[]A collection of indices to deselect.
ExtendSelect(params IListItem[])
Selects additional items from the multi-selection list, by ListItem items.
void ExtendSelect(params IListItem[] items)
Parameters
itemsIListItem[]The items to add to the selection.
ExtendSelect(params string[])
Selects additional items from the multi-selection list, by name.
void ExtendSelect(params string[] items)
Parameters
itemsstring[]The names of the items to add to the selection.
ExtendSelect(params uint[])
Selects additional items from the multi-selection list, by item indices.
void ExtendSelect(params uint[] itemIndices)
Parameters
itemIndicesuint[]The indices of the items to add to the selection.
GetItem(string)
Retrieves an item with the given text.
IListItem GetItem(string text)
Parameters
textstringThe text of this item.
Returns
Select(params IListItem[])
Selects a list of items in the list box.
void Select(params IListItem[] items)
Parameters
Select(params string[])
Selects items in the list based on the item names.
void Select(params string[] items)
Parameters
itemsstring[]A collection of item names to select.
Select(params uint[])
Selects items in the list based on the item indices.
void Select(params uint[] itemIndices)
Parameters
itemIndicesuint[]A collection of item indices to select.