SelectElement SelectByIndex Method WebDriver
Select the option by the index, as determined by the "index" attribute of the element.

Namespace: OpenQA.Selenium.Support.UI
Assembly: WebDriver.Support (in WebDriver.Support.dll) Version: 2.35.0.0 (2.35.0.0)
Syntax

public void SelectByIndex(
	int index
)

Parameters

index
Type: OnlineSystem Int32
The value of the index attribute of the option to be selected.
Exceptions

ExceptionCondition
OpenQA.Selenium NoSuchElementExceptionThrown when no element exists with the specified index attribute.
See Also