New version 3 released !
New blocks -
DeviceUtils.aix (6.5 KB)
(First post also updated)
Why I have Runtime Error...
Requires READ_PHONE_STATE:Neither user 10011 nor current process has android.permission.READ_PHONE_STATE.
-I have try block with and without AskForPermission
-I try on android 5.1.1
Thanks
@Ronald I think, this method is not supported on your device...
I dont use companion... I use apk direct to my android...
Its OK If its not support to my android... Thanks...
Also, instead of READ_PHONE_STATE
permission, try to ask for android.permission.READ_PRIVILEGED_PHONE_STATE
because the GetImei
and GetMeid
blocks require that permission, and make sure its granted.
Also, do you even have a IMEI number ? (If you don't have a sim slot, more chance is there that your device has no IMEI number...)
Also, this link might help...
Deviceid function of the phone manager extension no longer returns the id.
Third-party apps installed from the Google Play Store cannot declare privileged permissions.
https://developer.android.com/about/versions/10/privacy/changes
See this Как получить id с android 10?
Also, An alternative for imei is discussed here:
Can you provide me the AIX file of this program?
Please add KeepScreenOn block.
Already available here:
i know but i want in DeviceUtils.
no, i want KeepScreenOn option in DeviceUtils extension.
Why do you want that? This extension is only about giving device info. It doesn't make sense to add that block.
already have bluetooth enable or disable and status bar color change option.
And how to ask for READ_PRIVILEGED_PHONE_STATE from app inventor?
But how to do this from app inventor? I don't know about android Studio and the description given on this page is not related to app inventor.
AI2 is still targeting SDK 30 but will target SDK 31 in a few days. You will then have to manually change the targetSdkVersion (and set it to SDK 28) after decompiling the APK.
Note: This app will not be approved by Google in the Play Store.