Quantcast
Channel: Questions in topic: "keyboard"
Viewing all articles
Browse latest Browse all 605

How to keep opening of keyboard when focus transferred to another input field by programmatically.?

$
0
0
,Hi, I am working on OTP section. For this, I have 6 input fields and one submit button. And also, I have written script for auto focus by following code. number1.onValueChanged.AddListener((text) => { number2.Select(); number2.ActivateInputField(); }); But, these lines did not work. I tried various possible solutions. But, the keyboard reopen when other inputfield get activated. I have also tested with StartCoroutine() to delay the selecting and activating input field. number1.onValueChanged.AddListener((text) => { //number1.DeactivateInputField(); StartCoroutine(SelectInputField(number2)); }); IEnumerator SelectInputField(TMP_InputField inputField) { yield return new WaitForSeconds(0.5f); inputField.ActivateInputField(); } Please suggest any possible solution / trick to keep opening of keyboard when focus transferred to another inputfield.

Viewing all articles
Browse latest Browse all 605

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>