2

My app needs to do the following thing, right when I turn it on it reads the devices ID (the unique ID each device has) and then saves that into a Variable. I can do the saving no problem.

I was hoping any of you know how to do that? I can't seem to find info on how to extract this ID from the device. I need my app to run on a non-root device too

KP Nany
  • 23
  • 4

2 Answers2

0
android.os.Build.DEVICE;
android.os.Build.MODEL;
android.os.Build.SERIAL;
usajnf
  • 522
  • 3
  • 11
0

Keep in mind that Device ID's can theoretically be changed if the user flashes a new ROM. There's no ID that I'm aware of (though Google may have recently added one, I'm not sure) that lets you know with 100% certainty that you're always on a specific device.

Josh Kitchens
  • 1,080
  • 11
  • 18