Detect Incoming call in Android programmatically

To detect incoming call and number in Android programmatically just follow below steps. 1) Add these permission in Manifest file. <uses-permission android:name=”android.permission.READ_PHONE_STATE”/> <uses-permission android:name=”android.permission.PROCESS_OUTGOING_CALLS”/> 2) Create a receiver class to handle incoming call & update it in manifest file <receiver android:name=”com.example.calllogreaderexample.TelephonyReceiver”> <intent-filter>Continue reading… Detect Incoming call in Android programmatically

Read call Logs in Android example

Read call logs in Android here are the simple steps. 1) Update Manifest file with following permissions. <uses-permission android:name=”android.permission.READ_CALL_LOG”/> <uses-permission android:name=”android.permission.WRITE_CALL_LOG”/> <uses-permission android:name=”android.permission.READ_CONTACTS” /> <uses-permission android:name=”android.permission.WRITE_CONTACTS”/> 2) Use CallLog.Calls.CONTENT_URI to read call logs & traverse the cursor. //Fetches the complete callContinue reading… Read call Logs in Android example