Skip to content Skip to sidebar Skip to footer

How To Automatically Re-query With Loadermanager

I have an app that shows data from a SQLite DB and the data changes constantly, so obviously, I thought I should use a LoaderManager to show the data. do I read a bit about using t

Solution 1:

the problem starts when the database is changed from a 'BroadcastListener' while the activity is still running... is there a way to automate re-query behind the scenes?

Have the BroadcastReceiver use the insert(), update(), replace(), and delete() methods on SQLiteCursorLoader to modify the database. Then, the Cursor will be re-loaded automatically.

Post a Comment for "How To Automatically Re-query With Loadermanager"