4

How to read the device name from phone setting in android, As shown in below image how to read the first field that is "device name" in android.

In some phones, the device name is the same as the model name but in some phones both are different so how to particular read device name from phone settings inenter image description here android?

Any help is appreciated!

2 Answers2

4

here you go

Settings.Global.getString(getContentResolver(), Settings.Global.DEVICE_NAME)
Priyanka
  • 3,369
  • 1
  • 10
  • 33
0

You can directly use this, Use in your logcat to see the result.

Build.DEVICE