c# - Selenim webdriver: IE 11 sendKeys - select all(Ctrl+A) text in input (textbox) -
i have method select text using (ctrl+a) use in automated tests.
public static void selecttext(iwebelement input) { actions actions = new actions(driver); actions.click(input).sendkeys(keys.control + "a").perform(); } in chrome , firefox method selecttext (working). in ie 11 not working. in ie types "a".
for example: in input text "lorem ipsum". in ie method appends 'a' end of value "lorem ipsuma".
my configuration: windows 8.1, selenium version 2.46.0, iedriverserver.exe (x86 version).
ie initialization
internetexploreroptions ieoptions = new internetexploreroptions(); ieoptions.enablenativeevents = false; iwebdriver driver = new internetexplorerdriver(ieoptions); do have idea how can fix it?
i'm using browser switch, when running ie11 use following code select all:
input.sendkeys(""); // focus element sendkeys.sendwait ("^a"); // use windows send input
Comments
Post a Comment