Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

MaxFreud

macrumors newbie
Original poster
Jan 5, 2011
22
0
Hi all.

Very simple problem:

I have two textfields. They're both supposed to take in only numbers, so in IB I set the keyboard type to number pad. The problem is that there is no "Done" button on a number pad by default.

So I was hoping to add one of those little toolbar on top of the keyboard to provide buttons for switching between fields and a "done" button. I can't for the life of me figure out how to do this. I tried with a UIToolbar, but that pushes the buttons to the left, and I want it on the right.

I know I can make the textfields give up firstResponder status with a background tap but I think that's really unintuitive for users if its the only means available.

Any ideas?
 
I use a toolbar for this. Just add a flexible space as the first item to force all the other buttons to the right.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.