Android獲取SIM卡狀態


TelephonyManager tm = (TelephonyManager)this.getSystemService(TELEPHONY_SERVICE);//取得系統服務

tm.getSimState();//獲取SIM卡的6種狀態,分別是TelephonyManager.SIM_STATE_ABSENT,TelephonyManager.SIM_STATE_UNKNOW

//TelephonyManager.SIM_NETWORK_LOCKED,TelephonyManager.SIM_PIN_REQUIRED,TelephonyManager.SIM_PUK_REQUIRED

//TelephonyManager.SIM_STATE_READY


發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章