So I have been looking around and trying different codes and I cant really achieve what I want. I hope to find what I seek here.
I am trying to make a custom number pad. This is the result I want:
But this is as close I get.
First problem is that I cant get the apply and cancel button to have borders. How can i fix that?
The second problem is that I want to add the +*# button on my number pad also. how on earth can i do that?
This is the code im working with:
self.numberToolbar = [[UIToolbar alloc]initWithFrame:CGRectMake(0, 0, 320, 50)];
self.numberToolbar.barStyle = UIBarStyleBlackTranslucent;
self.numberToolbar.items = [NSArray arrayWithObjects:
[[UIBarButtonItem alloc]initWithTitle:@"Cancel" style:UIBarButtonItemStylePlain target:self action:@selector(cancelNumberPad)],
[[UIBarButtonItem alloc]initWithBarButtonSystemItem:UIBarButtonSystemItemFlexibleSpace target:nil action:nil],
[[UIBarButtonItem alloc]initWithTitle:@"Apply" style:UIBarButtonItemStyleDone target:self action:@selector(doneWithNumberPad)],
nil];
[self.numberToolbar sizeToFit];
self.driverNumber.inputAccessoryView = self.numberToolbar;