Appium not able to set value in Credit card CVV field

Hi All, I am facing problem is setting value in CVV (Secured code ) field in card payment page. It is working in Android emulator but not working in real device (Sauce Labs)

I have tried:

  1. driver.getKeyboard().sendKeys(Keys.NUMPAD9);

  2. driver.pressKeyCode(AndroidKeyCode.SPACE, AndroidKeyMetastate.META_SHIFT_ON)

  3. ((AndroidDriver) driver).pressKey(new KeyEvent(AndroidKey.BUTTON_9));

  4. Robot robot = new Robot();
    robot.keyPress(KeyEvent.VK_9);

  5. SendKeys (Standard method)

Environment:
Appium version is latest
Java-clent : 7

Perhaps, there is some system security limitation. As a possible workaround I’d try to:

  • Paste the code into the field
  • Locate and tap keyboard buttons while the input focus is set

Thank you for quick response can you tell me how to, Paste the code into the field?

second option I have tried we locate element >>click on field and then >>SendKeys . but field remain blank…

how to, Paste the code into the field?

As a normal user would do it - long tap there and tap Paste badge

tried we locate element >>click on field and then >>SendKeys

I’m talking about tapping 1,2,3,etc buttons directly on the virtual keyboard like a user would do it. Perhaps, it would be necessary to enable enableMultiWindows setting to make it appear in the page source.