I’m working on an iOS app that requires the user to enter numbers into a UITextField using the keyboard type UIKeyboardTypeDecimalPad. However I just realized that there is no support for entering negative numbers, which is a requirement of the application.
Any ideas or thoughts on how I can accomplish this?
This clearly isn’t my best answer.. but i’m unable to delete it since it is accepted.
may this code will help you:
if you want a negative number just use “-”
this will work for decimal numbers