Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Getting Udid in android

I am developing an android application in which I want to get UDID of android emulator. How can i do it?

Thanks in advance, Tushar

like image 332
User Avatar asked Mar 25 '11 08:03

User


People also ask

How do I find my udid?

Document required with online application: Scanned copy of recent color photo. Scanned image of signature (Optional) Scanned copy of Address Proof (Aadhar/Driving License/State Domicile etc) Scanned copy of Identity Proof (Aadhar Card/PAN Card/Driving License etc)

What is UUID in Mobile?

UUIDs are specifically created to personalize the user's experience within the app. Such personally identifiable information (PII) should not be shared with external entities without the user's consent. Doing so would be considered a privacy violation. [1] Android Developers Google.

What is Android device ID used for?

A device ID is a unique, anonymized string of numbers and letters that identifies every individual smartphone or tablet in the world. It is stored on the mobile device and can be retrieved by any app that is downloaded and installed. Apps typically retrieve the ID for identification when talking to servers.


1 Answers

I'm not sure if this is what you're after but you could use: Settings.Secure.ANDROID_ID

public class YourActivity extends Activity {
    //...Omitted code
    public String getId() {
        String id = android.provider.Settings.System.getString(super.getContentResolver(), android.provider.Settings.Secure.ANDROID_ID);
        return id;
    }
}

Note that this isn't an IMEI number, if you need this use getDeviceId()

like image 181
firefox1986 Avatar answered Sep 20 '22 12:09

firefox1986