We have a AutoCompleteTextView which is able to read from the users-contact-data as a convenience. However some users complain about the “READ_CONTACT” Permission the App is enforcing at installation. Is there any Way to let the user Choose to grant this permission and use this feature, or deny it and loose the feature? If it is not possible at Runtime, maybe there is some other way? Building two Apps, one with that permission and one without is not an option!
We have a AutoCompleteTextView which is able to read from the users-contact-data as a
Share
Unfortunately, no.
You can build a main app without that permission, then create a plugin that holds the permission and securely interacts with the main app. This is a bit of an advanced technique. I cover it in one of my books, and here is the directory with sample projects demonstrating the host and the plugin. In my case, I am using
CallLoginstead ofContactsContract, though the permission (READ_CONTACTS) is the same.