/// <summary> /// Send to send tab keys to an element /// </summary> /// <param name="driver">The driver being extended</param> /// <param name="element">The element to send the tabs to</param> /// <param name="count">The number of times to send tab</param> public static void SendTabs(this DriverManager driver, string element, int count) { var tabs = new List <WebDriverKey>(); for (var i = 0; i < count; i++) { tabs.Add(WebDriverKey.Tab); } driver.SendSpecialKeys(element, tabs); }
public static void SendSpecialKeys(this DriverManager driver, string elementId, WebDriverKey key) { driver.SendSpecialKeys(elementId, new List <WebDriverKey> { key }); }
/// <summary> /// Send to send tab keys to an element /// </summary> /// <param name="driver">The driver being extended</param> /// <param name="element">The element to send the tabs to</param> /// <param name="count">The number of times to send tab</param> public static void SendTabs(this DriverManager driver, string element, int count) { driver.SendSpecialKeys(element, String.Concat(Enumerable.Repeat("Tab", count))); }