Device serial number

Ebic

Member
Licensed User
Longtime User
How can i obtain this id from my phone and other tablet ?

screenshot_15.png


Now, with the ph library using
B4X:
ph.GetSettings("android_id")
I just get this one : 200145745C12....
where is HT07PPL....etc.?

thanks.
 

TomK

Member
Licensed User
Longtime User
Hi Ebic,

I was running a little test the other day on serial numbers, and this is what my code looked like:

B4X:
Sub Process_Globals
   'These global variables will be declared once when the application starts.
   'These variables can be accessed from all modules.
   Dim ph1 As Phone
   
End Sub

Sub Globals
   'These global variables will be redeclared each time the activity is created.
   'These variables can only be accessed from this module.

End Sub

Sub Activity_Create(FirstTime As Boolean)
   Dim serialNo As String
   
   serialNo = ph1.GetDeviceId
   If FirstTime Then
      Msgbox(serialNo, "Your Serial Number")
   End If
   
   ExitApplication
   
End Sub

Would that get you what you want?
 
Upvote 0

Ebic

Member
Licensed User
Longtime User
Hi Tomk
I've tryed it but the response is the IMEI number
that is different by the serial that i wont.

Thanks
 
Upvote 0

pjsmith

Member
Licensed User
Longtime User
Hi,

Did you find a solution? I actually just went down a similar route using phone.getdeviceid. Didn't realise until I installed on a tablet that devices that are wifi only don't have this string.

I'm looking for a unique ID that will stay the same to identify each device. Serial number would be my next best bet I guess.
 
Upvote 0

Derek Jee

Active Member
Licensed User
Longtime User
Hello

Can this android_id be found when navigating the device though the settings menu on the device.. I want to get the device id and be able to see the same id on the device somewhere. I got the id in code but cannot correlate it to any ids I see.. I have a Galaxy Tab S.. Thanks,


Derek.
 
Upvote 0
Top