Add +/- button on decimal keyboard

268 views Asked by At

I need a text entry with +/- button on decimal keyboard like below image. Can anyone advise me how to achieve this.

Desire keyboard image

1

There are 1 answers

2
Randy On

A solution could be to add a UIButton over your keyboard and then link this button to your UITextField. To access your keyboard view, you can do as follows :

[[[UIApplication sharedApplication] windows] objectAtIndex:1];

That's not a very clean solution though.

Edit : Here is an example given by iGW ( he adds a done button to his keyboard ) :

https://stackoverflow.com/a/25971206/3844377