SelectElementDeselectByValue Method WebDriver
Deselect the option having value matching the specified text.

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

public void DeselectByValue(
	string value
)

Parameters

value
Type: SystemString
The value of the option to deselect.
Exceptions

ExceptionCondition
InvalidOperationExceptionThrown when attempting to deselect option from a SELECT that does not support multiple selections.
NoSuchElementExceptionThrown when no element exists with the specified value attribute.
Remarks

When given "foo" this method will deselect an option like:

<option value="foo">Bar</option>

See Also

Reference