0

I'm having an app which shows the recent call logs as a listview.

I need to update the listview simultaneously with recent call logs. i.e. when i have made an 'out going call' or got a 'missed call', it will shown in the list view on the same time.

How can i achieve this. Please advise!

Thanks.

Shyam
  • 871
  • 6
  • 15
  • 30

1 Answers1

2

Content observer can be used to listen for any changes in the data. Since call logs are also stored in the DB table you can register content observer for call logs URI and you would be notify for changes in the call logs table. Check out this link for how to add content observer.

This post has some some sample code that you can use.

Community
  • 1
  • 1
Praful Bhatnagar
  • 7,425
  • 2
  • 36
  • 44