I finally fixed this problem

I needed to run a requery() on the cursor

cursor.requery();
myAdapter.notifyDataSetChanged();



On Oct 15, 10:05 am, jax <[email protected]> wrote:
> I have a CursorAdapter attached to a ListView, the ListView contains
> checkboxes for every row.
>
> When I check/uncheck a checkbox in a row it will update it to a 0 or 1
> in the database (This is working fine)
>
> I also have another checkbox in the same Activity that when pressed
> will disable all the checkboxes in the ListView [ setEnabled(false) ].
>
> The problem is that when I press this checkbox the ListView checkboxes
> return to their initial state when I started the activity.  It does
> not matter the number of checkboxes I changed during the activity.
>
> However, if I press the back button and then re-enter the activity all
> modifications are saved because the Cursor is refreshed.
>
> I am calling notifyDataSetChanged() at the end of the the methods that
> disables all the checkboxes.
>
> I also tried this for every checkbox in the ListView but it did not
> work (was unable to check a checkbox)
>
> Any ideas?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to