How can I get the UUID of my Android phone in an application?

后端 未结 7 2278
野趣味
野趣味 2020-11-27 10:58

I\'m looking for help to get the UUID of my Android phone. I have searched the net and found one potential solution but it is not working in the emulator.

Here is th

7条回答
  •  夕颜
    夕颜 (楼主)
    2020-11-27 11:17

    Instead of getting IMEI from TelephonyManager use ANDROID_ID.

    Settings.Secure.ANDROID_ID
    

    This works for each android device irrespective of having telephony.

提交回复
热议问题