- Read sim details(Sim Number , Name) from Android call logs.
For Example : In My mobile have dual sim(SIM1,SIM2),While I Make a call using SIM1 Means, I need to get SIM1 all details after call cut.
For Example : In My mobile have dual sim(SIM1,SIM2),While I Make a call using SIM1 Means, I need to get SIM1 all details after call cut.
I have been working on such an app that performs call tests, both from calling sim1 and sim2. the fact is when make call, you can get SIM Serial Number (IMSI) and Sim Number by following line of codes,
String IMSI = telephonyManager.getSubscriberId();
String phoneNumber =telephonyManager.getLine1Number();
note: some sim cards does not contain phone number, in that case code will return null or empty string. visit this link