I'm trying to write a function for the Android platform that will allow me to call 911 without any sort of prompt.
I have already added the permission android.permission.CALL_PRIVILEGED
. I just need a function that will dial 911 at the press of a button in my options menu.
According to the API, ACTION_CALL will do what you need but not to emergency numbers, while ACTION_DIAL will display a dialer with the dial prompt but allows to call emergency numbers.
I'm afraid there is no way to do what you want, for a good reason - to prevent misdials to emergency services. It's a precautionary measure.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With