0

How can I get UDID of Android device via adobe air? I want to get UDID of my device with Android OS installed on it via Adobe AIR. How can I do it? Thanx!

yozhik
  • 4,644
  • 14
  • 65
  • 98

3 Answers3

1

It doesn't look like it's in the APIs. You can try generating a random code and storing it on the device. This has been asked before here: Get unique identifier (MAC address, UDID, etc...) in Adobe AIR for iOS and recently here: http://www.flexdeveloper.eu/forums/actionscript-3-0/detecting-unique-device-number-in-adobe-flex-like-udid-of-iphone-device/

Community
  • 1
  • 1
Rob
  • 2,779
  • 5
  • 23
  • 34
  • so, I can only get MAC address but not UDID?? – yozhik Sep 06 '11 at 13:32
  • Through the Adobe Flex platform, yes. You can generate and store your own random value, though, which accomplishes just about the same thing in most cases. – Rob Sep 06 '11 at 13:42
0

You can't do that directly on AdobeAir. But you may build an ANE to do just that. You may want to have a look at this other solution we have posted here, with the the required ANE for this purpose: https://stackoverflow.com/a/43338213/247658

Community
  • 1
  • 1
Hadi tavakoli
  • 1,267
  • 2
  • 16
  • 30
0

you can use TelephonyManager.getDeviceId() to get udid of a device.

Add this permission:

<uses-permission android:name="android.permission.READ_PHONE_STATE" />

you can refer this doc:

http://developer.android.com/reference/android/telephony/TelephonyManager.html#getDeviceId%28%29

also check:

Unique ID of Android device

Community
  • 1
  • 1
Vineet Shukla
  • 23,865
  • 10
  • 55
  • 63