Android provides an API to get the SIM card number, that is, to get the phone number of the local machine through telephonmanager.
It is particularly mentioned that information on the Internet shows that the new version of the dynamic zone card cannot be obtained. Is it unclear whether it is true? My card can be obtained, thank you! The remedy is to send an email to 10086 (10010) and then get the email from the sender ......
PS: Some developers cannot read the phone number. I will explain it to you below. The reason is that the operator did not input data to the corresponding API in the phone card. The previous cards were all input, and new cards were not input. Why? I guess it may be to save costs ......
MethodCode:
Telephonymanager telephonmanager = (telephonymanager) getsystemservice (context. telephony_service); string telephonenumber = telephonmanager. getline1number ();
Permissions in manifest:
<Uses-Permission Android: Name = "android. Permission. read_phone_state"/>
Engineering Resources: http://download.csdn.net/detail/etzmico/3975400