get IMEI - Android Phone

Android examples for Phone:wifi

Description

get IMEI

Demo Code


//package com.java2s;

import android.content.Context;

import android.telephony.TelephonyManager;

public class Main {
    public static String getIMEI(Context context) {
        return ((TelephonyManager) context.getSystemService("phone"))
                .getDeviceId();/* w  ww  . j av  a 2  s  . com*/
    }
}

Related Tutorials