Table of Contents

Interface IKeyboard

Namespace
OpenQA.Selenium
Assembly
WebDriver.dll

Provides methods representing basic keyboard actions.

public interface IKeyboard

Methods

PressKey(string)

Presses a key.

void PressKey(string keyToPress)

Parameters

keyToPress string

The key value representing the key to press.

Remarks

The key value must be one of the values from the Keys class.

ReleaseKey(string)

Releases a key.

void ReleaseKey(string keyToRelease)

Parameters

keyToRelease string

The key value representing the key to release.

Remarks

The key value must be one of the values from the Keys class.

SendKeys(string)

Sends a sequence of keystrokes to the target.

void SendKeys(string keySequence)

Parameters

keySequence string

A string representing the keystrokes to send.