question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

SendKeys() using unknown keyboard configuration instead of local (azerty vs qwerty-like)

See original GitHub issue

I’m using Appium to automate our new app. My first attempts is as simple as the code below. Here we use the AZERTY keyboard configuration.

However, the text entered in the app is with a QWERTY-like configuration, so “aaa” comes out as “qqq”. My “regular” Selenium tests never had this issue. However, trying out all the keys gave me some weird results. For example, I get the colon character twice from different keys, but no dot character… So it’s not a correct QWERTY either.

DesiredCapabilities appCapabilities = new DesiredCapabilities();
appCapabilities.SetCapability("app", "Company.NewApp_nhrabtd3q6ea2!App");
appCapabilities.SetCapability("platformName", "Windows");
appCapabilities.SetCapability("deviceName", "WindowsPC");

MobileFormsSession = new WindowsDriver<WindowsElement>(new Uri(WindowsApplicationDriverUrl), appCapabilities);

MobileFormsSession.FindElementByAccessibilityId("username").SendKeys("aaa");

Issue Analytics

  • State:open
  • Created 6 years ago
  • Reactions:8
  • Comments:25 (1 by maintainers)

github_iconTop GitHub Comments

9reactions
xiler8commented, Jan 16, 2020

Bump! This needs to be fixed…

6reactions
CyrilJcommented, Oct 20, 2017

The copy past workaround won’t work if driving an app remotely. Can you fix this bug. It’s annoying to switch keyboard during development one for testing and one for developing. It’s hard to test mutlilanguages application

Read more comments on GitHub >

github_iconTop Results From Across the Web

sendKeys applies QWERTY-Style on German Keyboard ...
I set US keyboard layout to ctrl+0 and my local keyboard layout to ctrl+1 and in my testcode I am using the shortcuts...
Read more >
powershell sendkeys doesn't work properly with arabic ...
The SendKeys method is used to send keystrokes to the currently active window as if they where typed from the keyboard. So SendKeys...
Read more >
WinAppDriver / AZERTY Keyboard : sendkeys() doesn't ...
I try to use WinAppDriver for my UI test. Sendkeys() sends QWERTY txt, while I use AZERTY layout. I manage to relace characters...
Read more >
SendKeys statement (VBA)
Each key is represented by one or more characters. To specify a single keyboard character, use the character itself.
Read more >
SendKeys.Send(String) Method (System.Windows.Forms)
To specify characters that aren't displayed when you press a key, such as ENTER or TAB, and keys that represent actions rather than...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found