Hi Lam Try follow code snippet to check state of keyboard is active or not: InputMethodManager InputMethod = (InputMethodManager) getSystemService(Context.INPUT_METHOD_SERVICE); /* Check keyboard is active or not */ this.m_InputMethod.isActive();
But i think handle "Back" key event to close search box is better than check state of keyboard. Regards, DatNQ On Thu, Mar 24, 2011 at 9:17 AM, pk Lam <[email protected]> wrote: > Hi > > I have a search box that is made visible only during search which will show > up the soft keyboard. > > when the user tap the "Back" button, the keyboard is closed but my search > box is still visible. > > I would like to know how I could listen to soft keyboard close event so > that I could also hide the search box to terminate the search. > > thanks in advance! > > regards > pk > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

