How can I focus on a collapsible action view EditText item in the action bar (when it is expanded) and force the soft keyboard to open?
I am using Jake Wharton's excellent ActionBarSherlock library and have a collapsible search action view. I want to popup the soft keyboard when the search action view is expanded. We can read a recommended way of doing this in a DialogFragment in the " Using DialogFragments " blog post by Google (altered a bit for readability). // Show soft keyboard automatically mEditText.requestFocus(); int mode = WindowManager.LayoutParams.SOFT_INPUT_STATE_VISIBLE; getDialog().getWindow().setSoftInputMode(mode); This does not seem to work when expanding and requesting focus on a collapsable EditText action