I am implementing fingerprint authentication on my app. If the user hasn't set up a fingerprint on his device. I am trying to open system settings for enrolling fingerprints. According to documentation(https://developer.android.com/training/sign-in/biometric-auth), this is the code for opening the setting activity for enrolling fingerprint.
final Intent enrollIntent = new Intent(Settings.ACTION_BIOMETRIC_ENROLL);
enrollIntent.putExtra(Settings.EXTRA_BIOMETRIC_AUTHENTICATORS_ALLOWED,
BIOMETRIC_STRONG | DEVICE_CREDENTIAL);
startActivityForResult(enrollIntent, REQUEST_CODE);
I have tested the app on two devices. In Samsung, the code is working. But in an Asus device, it is not working.
As in the Google documentation "ACTION_BIOMETRIC_ENROLL" added at API 30, that's what causes your app to crash
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