Android Question Show Keyboard on activity change

Discussion in 'Android Questions' started by Derek Jee, Jul 13, 2015.

  1. Derek Jee

    Derek Jee Active Member Licensed User

    HI there

    Can someone tell me how to show the keyboard immediately an activity is open. I have set focus to an edit box but want the keyboard to show without having to click it..

    Thank you!!

    Derek.
     
  2. DonManfred

    DonManfred Expert Licensed User

    get inspired here.
     
    ArminKH likes this.
  3. Derek Jee

    Derek Jee Active Member Licensed User

    Thank you Manfred.

    I have looked here already and can get the keyboard to show on a click event but cannot get it to show on activity create. Is there a way for it to show immediately the user open the activity?

    Thank you for responding,

    Derek.
     
  4. DonManfred

    DonManfred Expert Licensed User

    You should call the showkeyboard of the ime library on activity resume; not in activity create. Nothing is hown in activityCreate. Just declared or layouts loaded. But you´ll get the layout shown after you pass the activityResume.
     
    lemonisdead, Derek Jee and ArminKH like this.
  5. ArminKH

    ArminKH Well-Known Member

    use ime library
    also we can use callsubdelayed on activity create to show the keyboard
    Code:
    sub ShowKeyboard
    IME1.ShowKeyboard
    end sub

    Sub Activity_Create(FirstTime as boolean)
    Callsubdelayed(me,
    "ShowKeyboard")
    end sub
     
    Derek Jee, RandomCoder and DonManfred like this.
  6. Derek Jee

    Derek Jee Active Member Licensed User

    Thank you Manfred.. Rookie mistake. I still couldn't get it to show though..

    Kind regards,

    Derek.
     
  7. Derek Jee

    Derek Jee Active Member Licensed User

    This worked for me, thank you Armin..
     
    ArminKH likes this.
Loading...