Category : android-10.0

According to docs: P.S. I know it is a bad practice, but that’s my client’s requirement. My client app requires IMEI number as parameter in an API call, to identify Vehicle owner in an android app. But I have two problems : READ_PRIVILEGED_PHONE_STATE Permission is only granted to system apps. Using getDeviceId to get device ..

Read more

I am developing an Android Xamarin Forms app which connects to a wifi programmatically. I used ConnectivityManager and NetworkCallback classes to achieve this. Everything works fine, I can connect to the wifi successfully, pressing the "Connect" (Connetti) button of the dialog shown below. Sometimes the required network is not detected and, a after a certain ..

Read more

Since getExternalStorageDirectory() is deprecated on Android 10 (API 29), I’m using context.getExternalFilesDir() for storing downloaded files in internal storage by granting Manifest.permission.WRITE_EXTERNAL_STORAGE, but as per documentation: This is like getFilesDir() in that these files will be deleted when the application is uninstalled I am not targeting SAF, as I don’t want to let user chooses ..

Read more

I have a use case where I need to make an Activity transparent. My Activity extends from AppCompatActivity, so I am using a theme style to make the Activity transparent: <style name="AppTheme.Transparent" parent="Theme.AppCompat.Light.NoActionBar"> . . . <item name="android:windowTranslucentStatus">true</item> <item name="android:windowIsTranslucent">true</item> . . . </style> Applying this theme on my Activity does make it transparent, but ..

Read more