SendKeys PageDown not working in IE

45 views
Skip to first unread message

Chris

unread,
Mar 29, 2018, 9:23:39 AM3/29/18
to Selenium Users
Hello -

I have an automation test where I need to scroll down in a table on the page. In my method I use SendKeys to send the pageDown key and it works great in Chrome.  in IE, nothing happens.  I've tried clicking and moving to the active element first before sending the key, and I've also tried using the actions class. 

Below is some of the code I've tried to get it to work.
// Send the PgDn key to scroll the table down.
                                IWebElement element = Common.commonWebDriver.SwitchTo().ActiveElement();
                                element.SendKeys(Keys.PageDown);
                               // new Actions(Common.commonWebDriver).SendKeys(OpenQA.Selenium.Keys.PageDown).Build().Perform();

Here is a JSFiddle showing the table within the page (I'm a noob to jsfiddle, so hopefully the link and the fiddle works).

We are currently using Selenium version 3.6.0 and .NETFramework 4.5.2.
IE Verrsion 11.15.16299
Chrome Version 63

thanks in advance for assistance.

Chris

unread,
Apr 15, 2018, 5:14:10 PM4/15/18
to Selenium Users
I found a work around that works in both IE and Chrome. 


System.Windows.Forms.SendKeys.SendWait("{PGDN}");
Reply all
Reply to author
Forward
0 new messages