Use “ENTER” key on softkeyboard instead of clicking button

You do it by setting a OnKeyListener on your EditText. Here is a sample from my own code. I have an EditText named addCourseText, which will call the function addCourseFromTextBox when either the enter key or the d-pad is clicked. addCourseText = (EditText) findViewById(R.id.clEtAddCourse); addCourseText.setOnKeyListener(new OnKeyListener() { public boolean onKey(View v, int keyCode, KeyEvent event) … Read more

Go vs. return button in iOS keyboard for HTML input forms

Update 2020/2021 As Cameron Cobb pointed out, Safari Mobile supports the new HTML attribute enterkeyhint since version 13.7 ~ Sept. 2020 (https://caniuse.com/mdn-html_global_attributes_enterkeyhint). The following values are possible (https://mixable.blog/ux-improvements-enterkeyhint-to-define-action-label-for-the-keyboard-of-mobile-devices/): <input enterkeyhint=”enter”> <input enterkeyhint=”done”> <input enterkeyhint=”go”> <input enterkeyhint=”next”> <input enterkeyhint=”previous”> <input enterkeyhint=”search”> <input enterkeyhint=”send”> Original Answer Aha… The ‘Go’ button is only shown, if the <input> tag … Read more

UISearchbar clearButton forces the keyboard to appear

This is an old question and I just came across the same issue and managed to solve it the following way: When the searchBar:textDidChange: method of the UISearchBarDelegate gets called because of the user tapping the ‘clear’ button, the searchBar hasn’t become the first responder yet, so we can take advantage of that in order … Read more

How to reliably detect if an external keyboard is connected on iOS 9?

After going back to the original question, I’ve found a solution that works. It seems that when the regular virtual keyboard is displayed the keyboard frame is within the dimensions of the screen. However when a physical keyboard is connected and the keyboard toolbar is displayed, the keyboard frame is located offscreen. We can check … Read more

Get UITableView to scroll to the selected UITextField and Avoid Being Hidden by Keyboard

In my app, I have successfully used a combination of contentInset and scrollToRowAtIndexPath like this: When you want to display the keyboard, just add a contentInset at the bottom with your table with desired height: tableView.contentInset = UIEdgeInsetsMake(0, 0, height, 0); Then, you can safely use [tableView scrollToRowAtIndexPath:[NSIndexPath indexPathForRow:cell_index inSection:cell_section] animated:YES]; By adding the contentInset, … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)