I am trying to replace the Standard Keyboard on the iPhone with a custom one which I have created in MainKeyboard.xib, which is linked to the UIView outlet mainKeyboard. I have the following code that executes when the main view loads, and I have also tried triggering it with a UIButton for testing purposes.
[[NSBundle mainBundle] loadNibNamed:@"MainKeyboard" owner:self options:nil];
[textView resignFirstResponder];
textView.inputView = mainKeyboard;
[textView becomeFirstResponder];
However, nothing happens to the keyboard. Bizarrely, I have taken this code from my own iPad app where it works fine! Are there any differences between the way the iPhone and the iPad deal with the keyboard? Or am I just doing something silly?
Thanks in advance!
Dave