Tabbing between text fields is a no-brainer from HTML, but for native iOS, there is no standard support for doing so. This implementation uses a "category" on UIControl to add support for tabbing between controls, making data entry on iOS easy for the user.
- Copy UIControl+NextControl.h and UIControl+NextControl.m to your project.
- Assign the "nextControl" properties to your controls in Interface Builder.
- Assign the delegate of each control to the view controller.
- Choose a keyboard and set the "Return Key" to say "Next". (optional)
- Implment the delegate method "- (BOOL)textFieldShouldReturn:(UITextField *)textField" in your view controller.
- Set the first control to become first responder in "viewWillDisplay". (optional)
- (BOOL)textFieldShouldReturn:(UITextField *)textField
{
[textField transferFirstResponderToNextControl];
return NO;
}